Move PNC apply to separate Expr/Pattern variant

This commit is contained in:
Anthony Bullard 2025-01-07 17:22:19 -06:00
parent 96fc573b6b
commit 898b3f55e5
No known key found for this signature in database
70 changed files with 873 additions and 555 deletions

View file

@ -512,13 +512,14 @@ impl Problem {
| Problem::ReturnAtEndOfFunction { region }
| Problem::UnboundTypeVarsInAs(region)
| Problem::UnsuffixedEffectfulRecordField(region)
| Problem::SuffixedPureRecordField(region) => Some(*region),
| Problem::SuffixedPureRecordField(region)
| Problem::StmtAfterExpr(region) => Some(*region),
Problem::RuntimeError(RuntimeError::CircularDef(cycle_entries))
| Problem::BadRecursion(cycle_entries) => {
cycle_entries.first().map(|entry| entry.expr_region)
}
Problem::StmtAfterExpr(region) => Some(*region),
Problem::RuntimeError(RuntimeError::UnresolvedTypeVar)
| Problem::RuntimeError(RuntimeError::ErroneousType)
| Problem::RuntimeError(RuntimeError::NonExhaustivePattern)