Idris2/tests/idris2/basic019/expected

9 lines
409 B
Plaintext
Raw Normal View History

1/1: Building CaseBlock (CaseBlock.idr)
2020-08-18 15:36:34 +03:00
Main> Main.foo : (x : Nat) -> (case x of {0 => Nat -> Nat; S k => Nat})
Main> Prelude.elem : Eq a => a -> List a -> Bool
elem x [] = False
2020-07-08 02:55:55 +03:00
elem x (y :: ys) = (x == y) || Delay (elem x ys)
Main> PrimIO.io_bind : (1 _ : IO a) -> (1 _ : (a -> IO b)) -> IO b
io_bind (MkIO fn) k = MkIO (\1 w => let MkIORes x' w' = fn w in let MkIO res = k x' in res w')
Main> Bye for now!