mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-27 13:59:08 +00:00
Get rid of passing target_info a bunch
This commit is contained in:
parent
8495f3b085
commit
bc41db2a34
18 changed files with 154 additions and 287 deletions
|
@ -296,7 +296,7 @@ fn tag_id_from_data<'a, M: ReplAppMemory>(
|
|||
data_addr: usize,
|
||||
) -> i64 {
|
||||
let offset = union_layout
|
||||
.data_size_without_tag_id(&env.layout_cache.interner, env.target_info)
|
||||
.data_size_without_tag_id(&env.layout_cache.interner)
|
||||
.unwrap();
|
||||
let tag_id_addr = data_addr + offset as usize;
|
||||
|
||||
|
@ -420,8 +420,8 @@ fn jit_to_ast_help<'a, A: ReplApp<'a>>(
|
|||
LayoutRepr::Struct(field_layouts) => {
|
||||
let fields = [Layout::U64, layout];
|
||||
|
||||
let result_stack_size = LayoutRepr::struct_(env.arena.alloc(fields))
|
||||
.stack_size(&env.layout_cache.interner, env.target_info);
|
||||
let result_stack_size =
|
||||
LayoutRepr::struct_(env.arena.alloc(fields)).stack_size(&env.layout_cache.interner);
|
||||
|
||||
let struct_addr_to_ast = |mem: &'a A::Memory, addr: usize| match env
|
||||
.subs
|
||||
|
@ -1087,7 +1087,6 @@ fn struct_to_ast<'a, M: ReplAppMemory>(
|
|||
*layout1,
|
||||
label2,
|
||||
*layout2,
|
||||
env.target_info,
|
||||
)
|
||||
});
|
||||
|
||||
|
@ -1170,7 +1169,6 @@ fn struct_to_ast_tuple<'a, M: ReplAppMemory>(
|
|||
*layout1,
|
||||
label2,
|
||||
*layout2,
|
||||
env.target_info,
|
||||
)
|
||||
});
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue