git.iko.soy/rowtype-yoga/purescript-backend-optimizer
on main help sign in
19 lines 425 B history raw
1module Snapshot.Object01 where
3import Foreign.Object (Object, keys, member)
4import Foreign.Object.Unsafe (unsafeIndex)
6test1 :: Object Int -> Int
7test1 a = unsafeIndex a "foo"
9test2 :: Object Int -> Int
10test2 a = unsafeIndex a "foo.bar"
12test3 :: Object Int -> String -> Int
13test3 a b = unsafeIndex a b
15test4 :: Object Int -> Array String
16test4 obj = keys obj
18test5 :: Object Int -> Boolean
19test5 obj = member "wat" obj