Commit 7f172953 authored by John van Groningen's avatar John van Groningen

Merge branch '50-crash-on-already-defined-type-variables' into 'master'

Resolve crash on existentially qualified type variables that already appear in...

Closes #50

See merge request clean-compiler-and-rts/compiler!11
parents 00e07f57 28c890cd
......@@ -615,7 +615,9 @@ where
= addExistentionalTypeVariablesToSymbolTable cti_lhs_attribute cons_def.cons_exi_vars ti_type_heaps cs
(st_args, st_attr_env,class_defs,(ts, ti=:{ti_type_heaps}, cs))
= bind_types_of_cons cons_def.cons_type.st_args cti free_vars [] class_defs (ts, {ti & ti_type_heaps = ti_type_heaps}, cs)
(unused_exi_vars,th_vars,cs)
| not cs.cs_error.ea_ok
= (class_defs, ts, ti, cs)
# (unused_exi_vars,th_vars,cs)
= find_unused_existential_type_vars exi_vars [] ti_type_heaps.th_vars cs
(st_context,class_defs,ts,ti=:{ti_type_heaps},cs)
= bind_context_of_cons cons_def.cons_type.st_context cti class_defs ts { ti & ti_type_heaps = { ti_type_heaps & th_vars = th_vars } } cs
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment