add func overrides, to get rid of proc exit special case

This commit is contained in:
Pat Hickey
2020-06-23 16:29:11 -07:00
parent 49c62ee828
commit 69f81397a8
3 changed files with 72 additions and 6 deletions

View File

@@ -27,6 +27,11 @@ can be used to do name-based resolution."
},
// Error to return when caller module is missing memory export:
missing_memory: { wasi_common::wasi::Errno::Inval },
// Don't use the wiggle generated code to implement proc_exit, we need to hook directly into
// the runtime there:
function_override: {
wasi_snapshot_preview1:proc_exit => wasi_proc_exit
}
});
pub fn is_wasi_module(name: &str) -> bool {