format code & replace vec!(in arena;...) with arena.alloc([...])

This commit is contained in:
HajagosNorbert 2023-11-21 11:09:42 +01:00
parent 9c21ac1388
commit 6975294278
No known key found for this signature in database
GPG key ID: 807F4444870DB673
4 changed files with 22 additions and 14 deletions

View file

@ -8,7 +8,7 @@ use crate::layout::{
UnionLayout,
};
use bumpalo::collections::Vec;
use bumpalo::{Bump, vec};
use bumpalo::Bump;
use roc_collections::{MutMap, VecMap};
use roc_module::low_level::LowLevel;
use roc_module::symbol::{IdentIds, ModuleId, Symbol};
@ -907,7 +907,8 @@ impl<'a> TrmcEnv<'a> {
reuse: None,
};
let indices = vec![in env.arena; cons_info.tag_id as u64, recursive_field_index as u64].into_bump_slice();
let indices = arena
.alloc([cons_info.tag_id as u64, recursive_field_index as u64]);
let let_tag = |next| Stmt::Let(*symbol, tag_expr, *layout, next);
let get_reference_expr = Expr::GetElementPointer {