mirror of
https://github.com/anoma/juvix.git
synced 2024-12-12 04:43:18 +03:00
2baad15a41
* Enables new function syntax in local let-declarations * Closes #2251
12 lines
196 B
Plaintext
12 lines
196 B
Plaintext
-- pattern matching coverage in cases
|
|
module test002;
|
|
|
|
import Stdlib.Prelude open;
|
|
|
|
f (x : List Nat) : Nat :=
|
|
case x
|
|
| nil := 0
|
|
| x :: y :: _ := x + y;
|
|
|
|
main : Nat := f (1 :: 2 :: nil);
|