Merge pull request #3541 from rtfeldman/rocasync

Changes to get roc-async working
This commit is contained in:
Folkert de Vries 2022-07-18 19:22:07 +02:00 committed by GitHub
commit ca38ec4eb5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 158 additions and 164 deletions

View file

@ -4917,8 +4917,22 @@ pub fn build_proc<'a, 'ctx, 'env>(
)
}
RawFunctionLayout::ZeroArgumentThunk(_) => {
// do nothing
RawFunctionLayout::ZeroArgumentThunk(result) => {
// Define only the return value size, since this is a thunk
//
// * roc__mainForHost_1_Update_result_size() -> i64
let ident_string = proc.name.name().as_str(&env.interns);
let fn_name: String = format!("{}_1", ident_string);
let result_type = basic_type_from_layout(env, &result);
build_host_exposed_alias_size_help(
env,
&fn_name,
name,
Some("result"),
result_type,
);
}
}
}