mirror of
https://github.com/fluencelabs/wasm-bindgen
synced 2025-03-17 18:50:51 +00:00
This commit tweaks the codegen for imported functions and such (anything that relies on some imported intrinsic or function filled in by the CLI) to share as much code as possible on non-wasm32 platforms. This should help us catch more errors before compiling to wasm and also just make it easier to write UI tests! For example a UI test previously couldn't be written for #1528 but now it can be, and one is include (although the error message is quite bad).
10 lines
136 B
Rust
10 lines
136 B
Rust
use wasm_bindgen::prelude::*;
|
|
|
|
#[wasm_bindgen]
|
|
extern "C" {
|
|
#[wasm_bindgen]
|
|
pub fn foo() -> Result<JsValue, JsValue>;
|
|
}
|
|
|
|
fn main() {}
|