9eb4dc4a81
This commit affects different modules. I used the following approach: 1- I store the metavariable environment at unification_failure_justifications. The idea is to capture the set of instantiated metavariables at the time of failure. 2- I added a remove_detail function. It removes propagation steps from the justification tree object. I also remove the backtracking search space associated with higher-order unificiation. I keep only the search related to case-splits due to coercions and overloads. 3- I use the metavariable environment captured at step 1 when pretty printing the justification of an elaborator_exception. Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
67 lines
1.8 KiB
Text
67 lines
1.8 KiB
Text
Set: pp::colors
|
||
Set: pp::unicode
|
||
Assumed: f
|
||
Failed to solve
|
||
⊢ Bool ≺ ℕ
|
||
(line: 4: pos: 6) Type of argument 3 must be convertible to the expected type in the application of
|
||
@f
|
||
with arguments:
|
||
ℕ
|
||
10
|
||
⊤
|
||
Assumed: g
|
||
Error (line: 7, pos: 8) invalid expression, it still contains metavariables after elaboration, metavariable: ?M::1, type:
|
||
Type
|
||
Assumed: h
|
||
Failed to solve
|
||
x : ?M::0, A : Type ⊢ ?M::0 ≺ A
|
||
(line: 11: pos: 27) Type of argument 2 must be convertible to the expected type in the application of
|
||
h
|
||
with arguments:
|
||
A
|
||
x
|
||
Assumed: my_eq
|
||
Failed to solve
|
||
A : Type, B : Type, a : ?M::0, b : ?M::1, C : Type ⊢ ?M::0[lift:0:3] ≺ C
|
||
(line: 15: pos: 51) Type of argument 2 must be convertible to the expected type in the application of
|
||
my_eq
|
||
with arguments:
|
||
C
|
||
a
|
||
b
|
||
Assumed: a
|
||
Assumed: b
|
||
Assumed: H
|
||
Failed to solve
|
||
⊢ ?M::0 ⇒ ?M::3 ∧ a ≺ b
|
||
(line: 20: pos: 18) Type of definition 't1' must be convertible to expected type.
|
||
Failed to solve
|
||
⊢ b == b ≺ a == b
|
||
(line: 22: pos: 22) Type of argument 6 must be convertible to the expected type in the application of
|
||
@Trans
|
||
with arguments:
|
||
?M::1
|
||
a
|
||
a
|
||
b
|
||
Refl a
|
||
Refl b
|
||
Failed to solve
|
||
⊢ ?M::1 ≺ Type
|
||
(line: 24: pos: 6) Type of argument 1 must be convertible to the expected type in the application of
|
||
@f
|
||
with arguments:
|
||
?M::0
|
||
Bool
|
||
Bool
|
||
Failed to solve
|
||
a : Bool, b : Bool, H : (a ⇒ b) ⇒ a ⊢ a → (a ⇒ b) ⇒ a ≺ a → a
|
||
(line: 27: pos: 21) Type of argument 5 must be convertible to the expected type in the application of
|
||
@DisjCases
|
||
with arguments:
|
||
a
|
||
¬ a
|
||
a
|
||
EM a
|
||
λ H_a : a, H
|
||
λ H_na : ¬ a, NotImp1 (MT H H_na)
|