mirror of
https://github.com/roc-lang/roc.git
synced 2025-10-03 00:24:34 +00:00
fix tests and alias analysis
This commit is contained in:
parent
2e70bb8458
commit
457ba524aa
2 changed files with 15 additions and 25 deletions
|
@ -1265,13 +1265,14 @@ fn lowlevel_spec(
|
|||
let bag = builder.add_get_tuple_field(block, list, LIST_BAG_INDEX)?;
|
||||
let cell = builder.add_get_tuple_field(block, list, LIST_CELL_INDEX)?;
|
||||
|
||||
let _unit = builder.add_update(block, update_mode_var, cell)?;
|
||||
let _unit1 = builder.add_touch(block, cell)?;
|
||||
let _unit2 = builder.add_update(block, update_mode_var, cell)?;
|
||||
|
||||
// replace loads the old element and then inserts the new one.
|
||||
builder.add_bag_get(block, bag)?;
|
||||
builder.add_bag_insert(block, bag, to_insert)?;
|
||||
|
||||
with_new_heap_cell(builder, block, bag)
|
||||
let old_value = builder.add_bag_get(block, bag)?;
|
||||
let new_list = with_new_heap_cell(builder, block, bag)?;
|
||||
builder.add_make_tuple(block, &[new_list, old_value])
|
||||
}
|
||||
ListSwap => {
|
||||
let list = env.symbols[&arguments[0]];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue