mirror of
https://github.com/roc-lang/roc.git
synced 2025-10-02 00:01:16 +00:00
instantiate aliases with a function
This commit is contained in:
parent
f7010336bb
commit
b0ceaf0372
2 changed files with 21 additions and 16 deletions
|
|
@ -1966,13 +1966,12 @@ fn correct_mutual_recursive_type_alias<'a>(
|
|||
// Don't try to instantiate the alias itself in its definition.
|
||||
let original_alias_def = to_instantiate.remove(&rec).unwrap();
|
||||
|
||||
let helper = |s| to_instantiate.get(&s);
|
||||
|
||||
let mut new_lambda_sets = ImSet::default();
|
||||
alias.typ.instantiate_aliases(
|
||||
alias.region,
|
||||
&to_instantiate,
|
||||
var_store,
|
||||
&mut new_lambda_sets,
|
||||
);
|
||||
alias
|
||||
.typ
|
||||
.instantiate_aliases(alias.region, &helper, var_store, &mut new_lambda_sets);
|
||||
|
||||
for lambda_set_var in new_lambda_sets {
|
||||
alias
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue