This commit is contained in:
Folkert 2022-07-24 13:18:53 +02:00
parent c81e0281be
commit 9f37e73ae5
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C
2 changed files with 1 additions and 26 deletions

View file

@ -39,31 +39,6 @@ pub fn call_bitcode_fn<'a, 'ctx, 'env>(
})
}
pub fn call_list_bitcode_fn_old<'a, 'ctx, 'env>(
env: &Env<'a, 'ctx, 'env>,
args: &[BasicValueEnum<'ctx>],
fn_name: &str,
) -> BasicValueEnum<'ctx> {
use bumpalo::collections::Vec;
let parent = env
.builder
.get_insert_block()
.and_then(|b| b.get_parent())
.unwrap();
let list_type = super::convert::zig_list_type(env);
let result = create_entry_block_alloca(env, parent, list_type.into(), "list_alloca");
let mut arguments: Vec<BasicValueEnum> = Vec::with_capacity_in(args.len() + 1, env.arena);
arguments.push(result.into());
arguments.extend(args);
call_void_bitcode_fn(env, &arguments, fn_name);
env.builder.build_load(result, "load_list")
}
pub fn call_void_bitcode_fn<'a, 'ctx, 'env>(
env: &Env<'a, 'ctx, 'env>,
args: &[BasicValueEnum<'ctx>],

View file

@ -1,5 +1,5 @@
#![allow(clippy::too_many_arguments)]
use crate::llvm::bitcode::{build_dec_wrapper, call_list_bitcode_fn_old};
use crate::llvm::bitcode::build_dec_wrapper;
use crate::llvm::build::{
allocate_with_refcount_help, cast_basic_basic, Env, RocFunctionCall, Scope,
};