Get rid of special ModuleId for refcounting code

This commit is contained in:
Brian Carroll 2021-11-27 20:32:18 +00:00
parent 9bb5335c8d
commit ebc1fd6880
3 changed files with 17 additions and 18 deletions

View file

@ -79,8 +79,9 @@ pub fn helper_wasm<'a, T: Wasm32TestResult>(
use roc_load::file::MonomorphizedModule;
let MonomorphizedModule {
module_id,
procedures,
mut interns,
interns,
exposed_to_host,
..
} = loaded;
@ -112,17 +113,16 @@ pub fn helper_wasm<'a, T: Wasm32TestResult>(
let exposed_to_host = exposed_to_host.keys().copied().collect::<MutSet<_>>();
let refcount_home = interns.module_id(&"$RefCount".into());
let env = roc_gen_wasm::Env {
arena,
module_id,
interns,
exposed_to_host,
};
let (mut wasm_module, main_fn_index) =
roc_gen_wasm::build_module_help(&env, procedures, refcount_home).unwrap();
roc_gen_wasm::build_module_help(&env, procedures).unwrap();
T::insert_test_wrapper(arena, &mut wasm_module, TEST_WRAPPER_NAME, main_fn_index);