]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - tests/org.simantics.scl.compiler.tests/src/org/simantics/scl/compiler/tests/scl/FoldlBuild1.scl
Fixed all line endings of the repository
[simantics/platform.git] / tests / org.simantics.scl.compiler.tests / src / org / simantics / scl / compiler / tests / scl / FoldlBuild1.scl
index 21dfdea64a40f0af8c126c208be202c9332486a6..ab1c72de2094adc0e6bb9d388d583948e1f58ef1 100644 (file)
@@ -1,18 +1,18 @@
-import "Prelude"\r
-\r
-inc :: Ref Integer -> <Proc> Integer\r
-inc r = do \r
-    v = getRef r\r
-    newV = v+1\r
-    r := newV\r
-    newV\r
-\r
-main = do\r
-    r = ref 0\r
-    // Because both map and for get side-effectful functions\r
-    // as parameters, the fusion is not allowed.\r
-    l = map (\_ -> inc r) [1..4]    \r
-    for l (\i -> r := i+1)\r
-    getRef r\r
---\r
-5\r
+import "Prelude"
+
+inc :: Ref Integer -> <Proc> Integer
+inc r = do 
+    v = getRef r
+    newV = v+1
+    r := newV
+    newV
+
+main = do
+    r = ref 0
+    // Because both map and for get side-effectful functions
+    // as parameters, the fusion is not allowed.
+    l = map (\_ -> inc r) [1..4]    
+    for l (\i -> r := i+1)
+    getRef r
+--
+5