fix(frontends/lean/pp): bug in notation matching procedure

This commit is contained in:
Leonardo de Moura 2014-10-19 10:48:41 -07:00
parent d7cc7cbd8c
commit 100b3abf1d

View file

@ -609,9 +609,7 @@ bool pretty_fn::match(expr const & p, expr const & e, buffer<optional<expr>> & a
return true; return true;
} else if (is_placeholder(p)) { } else if (is_placeholder(p)) {
return true; return true;
} else if (is_constant(p)) { } else if (is_constant(p) && is_constant(e)) {
if (!is_constant(e))
return false;
levels p_ls = const_levels(p); levels p_ls = const_levels(p);
levels e_ls = const_levels(p); levels e_ls = const_levels(p);
while (!is_nil(p_ls)) { while (!is_nil(p_ls)) {