1 + 1 = 2

This commit is contained in:
2024-09-28 20:53:22 -07:00
parent 4f9c7fa8a9
commit beb7b1a623
7 changed files with 84 additions and 25 deletions

18
tests/black/caseeval.newt Normal file
View File

@@ -0,0 +1,18 @@
module CaseEval
data Nat : U where
Z : Nat
S : Nat -> Nat
plus : Nat -> Nat -> Nat
plus Z y = y
plus (S x) y = S (plus x y)
data Eq : {A : U} -> A -> A -> U where
Refl : {A : U} -> {x : A} -> Eq x x
two : Eq (plus (S Z) (S Z)) (S (S Z))
two = Refl
three : Eq (plus (S Z) (S (S Z))) (plus (S (S Z)) (S Z))
three = Refl {Nat} {S (S (S Z))}