]> gerrit.simantics Code Review - simantics/platform.git/blob - tests/org.simantics.scl.compiler.tests/src/org/simantics/scl/compiler/tests/scl/Sort2.scl
(refs #7307) Added features field to SCL module header
[simantics/platform.git] / tests / org.simantics.scl.compiler.tests / src / org / simantics / scl / compiler / tests / scl / Sort2.scl
1 import "JavaBuiltin" as Java
2
3 importJava "org.simantics.scl.runtime.Lists" where
4     sortWith :: (a -> a -> Integer) -> [a] -> [a]
5
6 //@JavaStaticMethod "org.simantics.scl.runtime.Lists.sortWith"
7 //sortWith :: (a -> a -> Integer) -> [a] -> [a]
8
9
10 //sortWith = Java.staticMethod "org.simantics.scl.runtime.Lists.sortWith"
11
12 dumbCompare :: a -> a -> Integer
13 dumbCompare x y = 0
14
15 dumbSort = sortWith dumbCompare 
16
17 main = "Foo"
18 --
19 Foo