Improve error pattern and fix tests

This commit is contained in:
ayazhafiz 2022-02-27 12:01:12 -05:00
parent 75cef24ee0
commit 720b7b49d2
3 changed files with 7 additions and 7 deletions

View file

@ -196,7 +196,7 @@ pub fn canonicalize_pattern<'a>(
env.problem(Problem::RuntimeError(RuntimeError::OpaqueNotApplied(
loc_name.clone(),
)));
Pattern::OpaqueNotInScope(loc_name)
Pattern::UnsupportedPattern(region)
}
Apply(tag, patterns) => {
let mut can_patterns = Vec::with_capacity(patterns.len());