report circular type error

This commit is contained in:
Folkert 2020-04-02 23:13:35 +02:00
parent 8642cfeae0
commit 2e822e739f
5 changed files with 304 additions and 42 deletions

View file

@ -437,7 +437,7 @@ pub fn constrain_expr(
ForReason(
Reason::IfBranch { index: index + 1 },
Type::Variable(*branch_var),
region,
loc_body.region,
),
);
@ -453,7 +453,7 @@ pub fn constrain_expr(
index: branches.len() + 1,
},
Type::Variable(*branch_var),
region,
final_else.region,
),
);