Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
lukaszcz committed Oct 30, 2024
1 parent 18c71b6 commit eefe780
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions tests/Compilation/negative/test011.juvix
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
-- Redundant pattern after a true side condition
module test011;

import Stdlib.Prelude open;

f (x : List Nat) : Nat :=
case x of
| nil := 0
| x :: _ :: nil := x
| _ :: _ :: _ :: _ if true := 0
| _ :: _ :: x :: nil := x
| _ :: nil := 1
| _ := 2;

main : Nat := f (1 :: 2 :: nil);

0 comments on commit eefe780

Please sign in to comment.