Open timsueberkrueb opened 2 weeks ago
The problem is that when we compute a unifying substitution for use in dependent pattern matching then unsolved metavariables shouldn't occur in the RHS of the substitution. Otherwise we might have accidental information flowing from inside a clause to the outside. (Cp. the problems described in the OutsideIn paper)
Consider the following example:
When printing the checked AST, we observe:
cargo run -- fmt --checked examples/foo.pol
Here,
a:=a
was substituted toa:=<a>
where<a>
is a hole corresponding to the inserted metavariable?0
from the scrutinee typeEq(?0, x, y)
.