mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-27 05:49:08 +00:00
remove tag_id in favor of index
This commit is contained in:
parent
347431d1df
commit
90223022af
8 changed files with 32 additions and 33 deletions
|
@ -206,11 +206,11 @@ fn specialize_drops_stmt<'a, 'i>(
|
|||
environment.symbol_tag.insert(*structure, *tag_id);
|
||||
}
|
||||
UnionFieldPtrAtIndex {
|
||||
structure, tag_id, ..
|
||||
structure, index, ..
|
||||
} => {
|
||||
// Generated code might know the tag of the union without switching on it.
|
||||
// So if we UnionFieldPtrAtIndex, we must know the tag and we can use it to specialize the drop.
|
||||
environment.symbol_tag.insert(*structure, *tag_id);
|
||||
environment.symbol_tag.insert(*structure, index[0] as u16);
|
||||
}
|
||||
Array {
|
||||
elems: children, ..
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue