Add async host functions
This commit is contained in:
parent
a5a0abb895
commit
4565f1a976
6 changed files with 96 additions and 91 deletions
|
@ -61,3 +61,11 @@ pub fn imports(x: u32) -> u32 {
|
|||
assert_eq!(x, b);
|
||||
a + b // should be 7 + x
|
||||
}
|
||||
|
||||
#[import]
|
||||
fn import_half(a: u32) -> u32;
|
||||
|
||||
#[export]
|
||||
pub fn half_async(a: u32) -> u32 {
|
||||
import_half(a)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue