fix(library/unifier): bug in unifier priority queue
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
This commit is contained in:
parent
608b66c323
commit
4a96fefd96
3 changed files with 18 additions and 0 deletions
|
@ -1892,6 +1892,12 @@ struct unifier_fn {
|
||||||
return process_delta(c);
|
return process_delta(c);
|
||||||
} else if (modified) {
|
} else if (modified) {
|
||||||
return is_def_eq(cnstr_lhs_expr(c), cnstr_rhs_expr(c), c.get_justification(), relax_main_opaque(c));
|
return is_def_eq(cnstr_lhs_expr(c), cnstr_rhs_expr(c), c.get_justification(), relax_main_opaque(c));
|
||||||
|
} else if (auto d = is_owned(c)) {
|
||||||
|
// Metavariable in the constraint is owned by choice constraint.
|
||||||
|
// choice constraint was postponed... since c was not modifed
|
||||||
|
// So, we should postpone this one too.
|
||||||
|
add_cnstr(c, to_cnstr_group(*d+1));
|
||||||
|
return true;
|
||||||
} else if (is_flex_rigid(c)) {
|
} else if (is_flex_rigid(c)) {
|
||||||
return process_flex_rigid(c);
|
return process_flex_rigid(c);
|
||||||
} else if (is_flex_flex(c)) {
|
} else if (is_flex_flex(c)) {
|
||||||
|
|
|
@ -5,6 +5,7 @@ if [ $# -ne 3 -a $# -ne 2 ]; then
|
||||||
fi
|
fi
|
||||||
ulimit -s unlimited
|
ulimit -s unlimited
|
||||||
LEAN=$1
|
LEAN=$1
|
||||||
|
export LEAN_PATH=../../../library/standard:.
|
||||||
if [ $# -ne 3 ]; then
|
if [ $# -ne 3 ]; then
|
||||||
INTERACTIVE=no
|
INTERACTIVE=no
|
||||||
else
|
else
|
||||||
|
|
11
tests/lean/run/coe7.lean
Normal file
11
tests/lean/run/coe7.lean
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
import logic
|
||||||
|
|
||||||
|
variable nat : Type.{1}
|
||||||
|
variable int : Type.{1}
|
||||||
|
variable of_nat : nat → int
|
||||||
|
coercion of_nat
|
||||||
|
|
||||||
|
theorem tst (n : nat) : n = n :=
|
||||||
|
have H : true, from trivial,
|
||||||
|
calc n = n : refl _
|
||||||
|
... = n : refl _
|
Loading…
Add table
Reference in a new issue