fix(tests/lean): adjust tests
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
This commit is contained in:
parent
a7f94b55db
commit
d2f9c24d3c
6 changed files with 16 additions and 29 deletions
|
@ -262,7 +262,7 @@ class elaborator::imp {
|
||||||
unsigned i = types.size();
|
unsigned i = types.size();
|
||||||
while (i > 0) {
|
while (i > 0) {
|
||||||
--i;
|
--i;
|
||||||
r = mk_lambda(name(g_x_name, i), types[i], r);
|
r = mk_lambda(i == 0 ? g_x_name : name(g_x_name, i), types[i], r);
|
||||||
}
|
}
|
||||||
return r;
|
return r;
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,4 +9,4 @@ Theorem R2 (A A' B B' : Type) (H : A → B = A' → B') (a : A) : B = B' := R A
|
||||||
Proved: R4
|
Proved: R4
|
||||||
Proved: R5
|
Proved: R5
|
||||||
Theorem R5 (A1 A2 B1 B2 : Type) (H : A1 → B1 = A2 → B2) (a : A1) : B1 = B2 :=
|
Theorem R5 (A1 A2 B1 B2 : Type) (H : A1 → B1 = A2 → B2) (a : A1) : B1 = B2 :=
|
||||||
R A1 A2 (λ a : A1, B1) (λ _ : A2, B2) H a
|
R A1 A2 (λ x : A1, B1) (λ x : A2, B2) H a
|
||||||
|
|
|
@ -5,4 +5,4 @@
|
||||||
Assumed: R
|
Assumed: R
|
||||||
Proved: R2
|
Proved: R2
|
||||||
Theorem R2 (A1 A2 B1 B2 : Type) (H : A1 → B1 = A2 → B2) (a : A1) : B1 = B2 :=
|
Theorem R2 (A1 A2 B1 B2 : Type) (H : A1 → B1 = A2 → B2) (a : A1) : B1 = B2 :=
|
||||||
R A1 A2 (λ a : A1, B1) (λ _ : A2, B2) H a
|
R A1 A2 (λ x : A1, B1) (λ x : A2, B2) H a
|
||||||
|
|
|
@ -9,22 +9,8 @@
|
||||||
Set: lean::pp::coercion
|
Set: lean::pp::coercion
|
||||||
∀ a b : ℤ, (g a (int_to_real (f a b))) > (nat_to_int 0)
|
∀ a b : ℤ, (g a (int_to_real (f a b))) > (nat_to_int 0)
|
||||||
λ a : ℕ, a + 1
|
λ a : ℕ, a + 1
|
||||||
Error (line: 10, pos: 18) ambiguous overloads
|
λ a b : ℕ, a + b
|
||||||
Candidates:
|
|
||||||
Real::add : ℝ → ℝ → ℝ
|
|
||||||
Int::add : ℤ → ℤ → ℤ
|
|
||||||
Nat::add : ℕ → ℕ → ℕ
|
|
||||||
Arguments:
|
|
||||||
a : ?M0[lift:0:2]
|
|
||||||
b : ?M2[lift:0:1]
|
|
||||||
λ a b c : ℤ, a + c + b
|
λ a b c : ℤ, a + c + b
|
||||||
Error (line: 17, pos: 19) ambiguous overloads
|
(λ a b : ℕ, a + b) 10 20
|
||||||
Candidates:
|
|
||||||
Real::add : ℝ → ℝ → ℝ
|
|
||||||
Int::add : ℤ → ℤ → ℤ
|
|
||||||
Nat::add : ℕ → ℕ → ℕ
|
|
||||||
Arguments:
|
|
||||||
a : ?M0[lift:0:2]
|
|
||||||
b : ?M2[lift:0:1]
|
|
||||||
Assumed: x
|
Assumed: x
|
||||||
λ a b : ℤ, a + x + b
|
λ a b : ℤ, a + x + b
|
||||||
|
|
|
@ -21,11 +21,12 @@ f::explicit N n1 n2
|
||||||
Proved: Pr
|
Proved: Pr
|
||||||
Axiom H1 : a = b ∧ b = c
|
Axiom H1 : a = b ∧ b = c
|
||||||
Theorem Pr : (g a) = (g c) :=
|
Theorem Pr : (g a) = (g c) :=
|
||||||
let κ::1 := Trans::explicit
|
Congr::explicit
|
||||||
N
|
N
|
||||||
a
|
(λ x : N, N)
|
||||||
b
|
g
|
||||||
c
|
g
|
||||||
(Conjunct1::explicit (a = b) (b = c) H1)
|
a
|
||||||
(Conjunct2::explicit (a = b) (b = c) H1)
|
c
|
||||||
in Congr::explicit N (λ x : N, N) g g a c (Refl::explicit (N → N) g) κ::1
|
(Refl::explicit (N → N) g)
|
||||||
|
(Trans::explicit N a b c (Conjunct1::explicit (a = b) (b = c) H1) (Conjunct2::explicit (a = b) (b = c) H1))
|
||||||
|
|
|
@ -5,9 +5,9 @@
|
||||||
Assumed: g
|
Assumed: g
|
||||||
Assumed: a
|
Assumed: a
|
||||||
Error (line: 5, pos: 6) type mismatch at application
|
Error (line: 5, pos: 6) type mismatch at application
|
||||||
g ⊤ (f _ a a)
|
g ⊤ (f ?M3::0 a a)
|
||||||
Function type:
|
Function type:
|
||||||
N → N → Bool
|
N → N → Bool
|
||||||
Arguments types:
|
Arguments types:
|
||||||
⊤ : Bool
|
⊤ : Bool
|
||||||
f _ a a : ?M0
|
f ?M3::0 a a : ?M3::0
|
||||||
|
|
Loading…
Reference in a new issue