comparison tests/recBad.ur @ 244:71bafe66dbe1

Laconic -> Ur
author Adam Chlipala <adamc@hcoop.net>
date Sun, 31 Aug 2008 08:32:18 -0400
parents tests/recBad.lac@cc193f680193
children
comparison
equal deleted inserted replaced
243:2b9dfaffb008 244:71bafe66dbe1
1 datatype list a = Nil | Cons of a * list a
2
3 fun append (t ::: Type) (ls1 : list t) (ls2 : list t) : list t =
4 case ls1 of
5 Nil => ls2
6 | Cons (h, t) => Cons (h, append t ls2)
7
8 (*val rec ones : list int = Cons (1, ones)*)
9 val rec ones = fn () => Cons (1, ones ())