git.iko.soy/rowtype-yoga/purescript-backend-optimizer
on main help sign in
15 lines 280 B history raw
1module Snapshot.EffectUnsafe01 where
3import Prelude
5import Effect (Effect)
6import Effect.Unsafe (unsafePerformEffect)
8test1 :: Int
9test1 = unsafePerformEffect (pure 1)
11test2 :: Effect Int -> Int
12test2 random = unsafePerformEffect do
13 n <- random
14 m <- random
15 pure (n + m)