diff --git a/crates/backend/src/codegen.rs b/crates/backend/src/codegen.rs index 51144931..abf7eecd 100644 --- a/crates/backend/src/codegen.rs +++ b/crates/backend/src/codegen.rs @@ -977,7 +977,9 @@ impl TryToTokens for ast::ImportFunction { } #[cfg(not(all(target_arch = "wasm32", not(target_os = "emscripten"))))] unsafe fn #import_name(#(#abi_arguments),*) -> #abi_ret { - drop((#(#abi_argument_names),*)); + #( + drop(#abi_argument_names); + )* panic!("cannot call wasm-bindgen imported functions on \ non-wasm targets"); } diff --git a/crates/typescript-tests/src/lib.rs b/crates/typescript-tests/src/lib.rs index 07047ff5..211dfff6 100644 --- a/crates/typescript-tests/src/lib.rs +++ b/crates/typescript-tests/src/lib.rs @@ -1,5 +1,5 @@ -mod custom_section; -mod getters_setters; -mod opt_args_and_ret; -mod simple_fn; -mod simple_struct; +pub mod custom_section; +pub mod getters_setters; +pub mod opt_args_and_ret; +pub mod simple_fn; +pub mod simple_struct;