(self: List<A>)
| 938 | * @category unsafe |
| 939 | */ |
| 940 | export const unsafeHead = <A>(self: List<A>): A => { |
| 941 | if (isNil(self)) { |
| 942 | throw new Error(getExpectedListToBeNonEmptyErrorMessage) |
| 943 | } |
| 944 | return self.head |
| 945 | } |
| 946 | |
| 947 | /** |
| 948 | * Unsafely returns the last element of the specified `List`. |
no test coverage detected