Module
Data.Pointed.Convert  
- Package
- purescript-pointed
- Repository
- vladciobanu/purescript-pointed
This module defines conversion functions between Can, Smash, and Wedge.
The examples assume that the pointed modules are imported qualified:
import Data.Pointed.Can as C
import Data.Pointed.Smash as S
import Data.Pointed.Wedge as W
#hulkSmash Source
hulkSmash :: forall b a. a -> b -> Wedge a b -> Smash a bConvert from Wedge to Smash, given default values for a and b.
> hulkSmash "world" 1 (W.Non :: Wedge String Int)
S.Non
> hulkSmash "world" 1 (W.One "hello" :: Wedge String Int)
S.Two "hello" 1
> hulkSmash "world" 1 (W.Eno 42 :: Wedge String Int)
C.Eno "world" 42