diff options
Diffstat (limited to 'test')
| -rw-r--r-- | test/c/poly_simple.expect | 1 | ||||
| -rw-r--r-- | test/c/poly_simple.sail | 15 |
2 files changed, 16 insertions, 0 deletions
diff --git a/test/c/poly_simple.expect b/test/c/poly_simple.expect new file mode 100644 index 00000000..8ab686ea --- /dev/null +++ b/test/c/poly_simple.expect @@ -0,0 +1 @@ +Hello, World! diff --git a/test/c/poly_simple.sail b/test/c/poly_simple.sail new file mode 100644 index 00000000..6630c638 --- /dev/null +++ b/test/c/poly_simple.sail @@ -0,0 +1,15 @@ +default Order dec + +val "print" : string -> unit + +union Poly ('a : Type) = { + Ctor : 'a +} + +function main() : unit -> unit = { + let x = Ctor(3 : int); + let y = Ctor("Hello, World!\n"); + match y { + Ctor(str) => print(str) + } +}
\ No newline at end of file |
