Skip to content

Commit

Permalink
Fix array_get's drop implementation.
Browse files Browse the repository at this point in the history
  • Loading branch information
azteca1998 committed Oct 4, 2024
1 parent cfd0f06 commit c6c4fcd
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/libfuncs/array.rs
Original file line number Diff line number Diff line change
Expand Up @@ -548,17 +548,17 @@ pub fn build_get<'ctx, 'this>(
let region = Region::new();
let block = region.append_block(Block::new(&[]));

let value = block.load(context, location, value_ptr, elem_ty)?;
drop_overrides_meta
.invoke_override(context, &block, location, &info.ty, value)?;

block.append_operation(scf::r#yield(&[], location));
region
},
{
let region = Region::new();
let block = region.append_block(Block::new(&[]));

let value = block.load(context, location, value_ptr, elem_ty)?;
drop_overrides_meta
.invoke_override(context, &block, location, &info.ty, value)?;

block.append_operation(scf::r#yield(&[], location));
region
},
Expand Down

0 comments on commit c6c4fcd

Please sign in to comment.