mirror of
https://github.com/roc-lang/roc.git
synced 2025-08-03 11:52:19 +00:00
add reuse info to normal Tag ir constructor
This commit is contained in:
parent
c4b0a2ec29
commit
463f739c06
8 changed files with 94 additions and 16 deletions
|
@ -1088,17 +1088,21 @@ pub(crate) fn build_exp_expr<'a, 'ctx>(
|
|||
arguments,
|
||||
tag_layout: union_layout,
|
||||
tag_id,
|
||||
..
|
||||
} => build_tag(
|
||||
env,
|
||||
layout_interner,
|
||||
scope,
|
||||
union_layout,
|
||||
*tag_id,
|
||||
arguments,
|
||||
None,
|
||||
parent,
|
||||
),
|
||||
reuse,
|
||||
} => {
|
||||
let reuse_ptr = reuse.map(|ru| scope.load_symbol(&ru.symbol).into_pointer_value());
|
||||
|
||||
build_tag(
|
||||
env,
|
||||
layout_interner,
|
||||
scope,
|
||||
union_layout,
|
||||
*tag_id,
|
||||
arguments,
|
||||
reuse_ptr,
|
||||
parent,
|
||||
)
|
||||
}
|
||||
|
||||
ExprBox { symbol } => {
|
||||
let (value, layout) = scope.load_symbol_and_layout(symbol);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue