]> gerrit.simantics Code Review - simantics/platform.git/blob - tests/org.simantics.scl.compiler.tests/src/org/simantics/scl/compiler/tests/scl/ListSyntax8.scl
Automatic execution of SCL tests in Maven
[simantics/platform.git] / tests / org.simantics.scl.compiler.tests / src / org / simantics / scl / compiler / tests / scl / ListSyntax8.scl
1 import "Prelude"\r
2 \r
3 a :: [Either Integer Integer]\r
4 a = [Left 1, Right 2, Left 3, Right 4]\r
5 \r
6 lefts :: [Either a b] -> [a]\r
7 lefts l = [x | Left x <- l] \r
8 \r
9 main :: [Integer]\r
10 main = lefts a\r
11 --\r
12 [1, 3]