]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - tests/org.simantics.scl.compiler.tests/src/org/simantics/scl/compiler/tests/scl/ExistentialData.scl
Fixed multiple issues causing dangling references to discarded queries
[simantics/platform.git] / tests / org.simantics.scl.compiler.tests / src / org / simantics / scl / compiler / tests / scl / ExistentialData.scl
index 62130b49f5388a465903827fe9635edd7cdb613b..7cb6873333972c9651db1630e06ca36a1dd83468 100644 (file)
@@ -1,23 +1,23 @@
-import "JavaBuiltin" as Java\r
-\r
-(+) = Java.iadd\r
-\r
-data Thunk a = /* forall s. */ Thunk s (s -> a)\r
-\r
-id :: a -> a\r
-id x = x\r
-\r
-runThunk :: Thunk a -> a\r
-runThunk (Thunk s f) = f s\r
-\r
-makeThunk :: a -> Thunk a\r
-makeThunk x = Thunk x id\r
-\r
-mapThunk :: (a -> b) -> Thunk a -> Thunk b\r
-mapThunk f (Thunk s g) = Thunk s (\x -> f (g x))\r
-\r
-a = makeThunk (13 :: Integer)\r
-b = mapThunk (\x -> x+1) a\r
-main = runThunk b\r
---\r
+import "JavaBuiltin" as Java
+
+(+) = Java.iadd
+
+data Thunk a = /* forall s. */ Thunk s (s -> a)
+
+id :: a -> a
+id x = x
+
+runThunk :: Thunk a -> a
+runThunk (Thunk s f) = f s
+
+makeThunk :: a -> Thunk a
+makeThunk x = Thunk x id
+
+mapThunk :: (a -> b) -> Thunk a -> Thunk b
+mapThunk f (Thunk s g) = Thunk s (\x -> f (g x))
+
+a = makeThunk (13 :: Integer)
+b = mapThunk (\x -> x+1) a
+main = runThunk b
+--
 14
\ No newline at end of file