fix(tests/lean): tests affected by new type class resolution procedure

This commit is contained in:
Leonardo de Moura 2015-10-27 15:33:45 -07:00
parent 50186e2db3
commit 20539d698f
6 changed files with 8 additions and 29 deletions

View file

@ -1,7 +1,7 @@
{x : ∈ S | x > 0} : set
{x : ∈ s | x > 0} : finset
@set.sep.{1} nat (λ (x : nat), @gt.{1} nat 11.source.to.has_lt x 0) S : set.{1} nat
@finset.sep.{1} nat (λ (a b : nat), nat.has_decidable_eq a b) (λ (x : nat), @gt.{1} nat 11.source.to.has_lt x 0)
(λ (a : nat), nat.decidable_lt 0 a)
@finset.sep.{1} nat (λ (x x_1 : nat), nat.has_decidable_eq x x_1) (λ (x : nat), @gt.{1} nat 11.source.to.has_lt x 0)
(λ (x : nat), nat.decidable_lt 0 x)
s :
finset.{1} nat

View file

@ -22,12 +22,12 @@ l' : list A,
IH : ∀ (x : @nodup A l'), P (@quot.mk (nodup_list A) (nodup_list_setoid A) (@subtype.tag (list A) (@nodup A) l' x)),
nodup_al' : @nodup A (@cons A a l'),
anl' : not (@list.mem A a l'),
H3 : @eq (list A) (@list.insert A (λ (a b : A), h a b) a l') (@cons A a l'),
H3 : @eq (list A) (@list.insert A (λ (x x_1 : A), h x x_1) a l') (@cons A a l'),
nodup_l' : @nodup A l',
P_l' : P (@quot.mk (nodup_list A) (nodup_list_setoid A) (@subtype.tag (list A) (@nodup A) l' nodup_l')),
H4 :
P
(@insert A (λ (a b : A), h a b) a
(@insert A (λ (x x_1 : A), h x x_1) a
(@quot.mk (nodup_list A) (nodup_list_setoid A) (@subtype.tag (list A) (@nodup A) l' nodup_l')))
⊢ P (@quot.mk (nodup_list A) (nodup_list_setoid A) (@subtype.tag (list A) (@nodup A) (@cons A a l') nodup_al'))
finset_induction_bug.lean:30:45: error: don't know how to synthesize placeholder
@ -44,12 +44,12 @@ l' : list A,
IH : ∀ (x : @nodup A l'), P (@quot.mk (nodup_list A) (nodup_list_setoid A) (@subtype.tag (list A) (@nodup A) l' x)),
nodup_al' : @nodup A (@cons A a l'),
anl' : not (@list.mem A a l'),
H3 : @eq (list A) (@list.insert A (λ (a b : A), h a b) a l') (@cons A a l'),
H3 : @eq (list A) (@list.insert A (λ (x x_1 : A), h x x_1) a l') (@cons A a l'),
nodup_l' : @nodup A l',
P_l' : P (@quot.mk (nodup_list A) (nodup_list_setoid A) (@subtype.tag (list A) (@nodup A) l' nodup_l')),
H4 :
P
(@insert A (λ (a b : A), h a b) a
(@insert A (λ (x x_1 : A), h x x_1) a
(@quot.mk (nodup_list A) (nodup_list_setoid A) (@subtype.tag (list A) (@nodup A) l' nodup_l')))
⊢ P (@quot.mk (nodup_list A) (nodup_list_setoid A) (@subtype.tag (list A) (@nodup A) (@cons A a l') nodup_al'))
finset_induction_bug.lean:16:5: error: failed to add declaration 'finset.induction₂' to environment, value has metavariables

View file

@ -1,5 +1,5 @@
namespace playground
namespace nat
check 2+3 -- Should produce error
check 2+3
end nat
end playground

View file

@ -1,8 +1 @@
namespace_bug.lean:3:6: error: type mismatch at application
@bit0 ?A
term
?A
has type
Type.{l_2}
but is expected to have type
Type.{l_3}
2 + 3 : ?A

View file

@ -1,10 +0,0 @@
import logic data.prod
open prod
set_option class.unique_instances true set_option pp.implicit true
theorem tst (A : Type) (H₁ : inhabited A) (H₂ : inhabited A) : inhabited (A × A) :=
_
set_option class.unique_instances false
theorem tst2 (A : Type) (H₁ : inhabited A) (H₂ : inhabited A) : inhabited (A × A) :=
_

View file

@ -1,4 +0,0 @@
unique_instances.lean:6:0: error: ambiguous class-instance resolution, there is more than one solution
@prod.is_inhabited A A H₂ H₂
and
@prod.is_inhabited A A H₂ H₁