]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - tests/org.simantics.scl.compiler.tests/src/org/simantics/scl/compiler/tests/scl/Lambda.scl
Fixed all line endings of the repository
[simantics/platform.git] / tests / org.simantics.scl.compiler.tests / src / org / simantics / scl / compiler / tests / scl / Lambda.scl
index 2316b30b4aa99a31c077114248ee83d1385a981c..2fdff75387ac4985c246b083c22d068f428949c3 100644 (file)
@@ -1,13 +1,13 @@
-\r
-data List a = Nil | Cons a (List a)\r
-\r
-map :: (a -> b) -> List a -> List b\r
-map f Nil        = Nil\r
-map f (Cons h t) = Cons (f h) (map f t)\r
-\r
-constMap :: a -> List b -> List a\r
-constMap c = map (\x -> c)\r
-\r
-main = constMap (5 :: Integer) (Cons (1 :: Integer) (Cons (2 :: Integer) (Cons (3 :: Integer) Nil)))\r
---\r
+
+data List a = Nil | Cons a (List a)
+
+map :: (a -> b) -> List a -> List b
+map f Nil        = Nil
+map f (Cons h t) = Cons (f h) (map f t)
+
+constMap :: a -> List b -> List a
+constMap c = map (\x -> c)
+
+main = constMap (5 :: Integer) (Cons (1 :: Integer) (Cons (2 :: Integer) (Cons (3 :: Integer) Nil)))
+--
 (Cons 5 (Cons 5 (Cons 5 Nil)))
\ No newline at end of file