git.iko.soy/rowtype-yoga/purescript-native
on golang help sign in
Add TCOCase example.
commit3dbc2c26db1baf5fed87d6242f6f7008ce400b5c authorPhil Freeman <paf31@cantab.net> dateWed 14 May 2014, 21:54 (12 years ago) parent1074a1a
1 file changed+10
examples/passing/TCOCase.purs+10
examples/passing/TCOCase.pursnew file+10
@@ -0,0 +1,10 @@
1+module Main where
2+
3+data Data = One | More Data
4+
5+main = Debug.Trace.trace (from (to 10000 One))
6+ where
7+ to 0 a = a
8+ to n a = to (n - 1) (More a)
9+ from One = "Done"
10+ from (More d) = from d