Idris2-boot/tests/idris2/basic004/Wheres.idr
Michael Morgan e6121e0935 Remove trailing whitespace from Idris sources.
This is the result of running the command:

$ find . -name '*.idr' -type f -exec sed -i -E 's/\s+$//' {} +

I confirmed before running it that this would not affect any markdown
formatting in documentation comments.
2019-10-25 14:24:25 -07:00

21 lines
417 B
Idris

module Wheres
import Stuff
reverse : List a -> List a
reverse xs = rev' Nil xs
where
rev' : List a -> List a -> List a
rev' acc Nil = acc
rev' acc (x :: xs) = rev' (x :: acc) xs
foo : Int -> Int
foo x = case isLT of
Yes => prim__mul_Int x 2
No => prim__mul_Int x 4
where
data MyLT = Yes | No
isLT : MyLT
isLT = ifThenElse (intToBool (prim__lt_Int x 20)) Yes No