git.iko.soy/rowtype-yoga/purescript-native
on cd4c708 help sign in
rowtype-yoga/purescript-native/examples/passing/ContextSimplification.purs
15 lines 300 B history raw
1module Main where
3import Prelude
4import Control.Monad.Eff.Console
6shout = log <<< (_ <> "!") <<< show
8-- Here, we should simplify the context so that only one Show
9-- constraint is added.
10usesShowTwice true = shout
11usesShowTwice false = logShow
13main = do
14 usesShowTwice true "Test"
15 log "Done"