mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-28 22:34:45 +00:00
Only recursive tag unions are relevant in illegal cycles
This commit is contained in:
parent
b8defcbc75
commit
e946b972f7
1 changed files with 1 additions and 1 deletions
|
@ -1628,7 +1628,7 @@ fn correct_mutual_recursive_type_alias<'a>(
|
|||
// because we need all the types to be deeply instantiated.
|
||||
let all_are_narrow = cycle.iter().all(|sym| {
|
||||
let typ = &pending_aliases.get(sym).unwrap().typ;
|
||||
typ.is_tag_union_like() && typ.is_narrow()
|
||||
matches!(typ, Type::RecursiveTagUnion(..)) && typ.is_narrow()
|
||||
});
|
||||
|
||||
if all_are_narrow {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue