diff options
| author | Alasdair Armstrong | 2018-02-26 16:08:32 +0000 |
|---|---|---|
| committer | Alasdair Armstrong | 2018-02-26 16:11:30 +0000 |
| commit | e91a8c8659d08178dfec45a06529ade208ded186 (patch) | |
| tree | 9d7191b96eef2cec20cf907912f50da1ff4f877f /test/typecheck | |
| parent | ee123e2876c4fa5ae000256caeb7eb810e8c05f8 (diff) | |
Fix missing case in pattern completeness check
Fixes #4
Diffstat (limited to 'test/typecheck')
| -rw-r--r-- | test/typecheck/pass/pat_completeness.sail | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/typecheck/pass/pat_completeness.sail b/test/typecheck/pass/pat_completeness.sail new file mode 100644 index 00000000..fd4a7757 --- /dev/null +++ b/test/typecheck/pass/pat_completeness.sail @@ -0,0 +1,11 @@ +union option ('a : Type) = {None, Some : 'a} + +union ast = {Foo : unit} + +let x : option(ast) = Some(Foo) + +let y : unit = match(x) { + Some(Foo) => (), + Some(a) => (), + None => () +}
\ No newline at end of file |
