-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ff8b683
commit c4b088c
Showing
7 changed files
with
84 additions
and
43 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
/* tslint:disable */ | ||
/* eslint-disable */ | ||
export function result_string(): string; | ||
export function result_void(): void; | ||
export function result_i32(): number; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
use wasm_bindgen::prelude::*; | ||
|
||
#[wasm_bindgen] | ||
pub fn result_string() -> Result<String, JsValue> { | ||
Err(JsValue::from(5i32)) | ||
} | ||
|
||
#[wasm_bindgen] | ||
pub fn result_void() -> Result<(), JsError> { | ||
Err(JsError::new("message")) | ||
} | ||
|
||
#[wasm_bindgen] | ||
pub fn result_i32() -> Result<i32, JsError> { | ||
Ok(1) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
(module $reference_test.wasm | ||
(type (;0;) (func (result i32 i32))) | ||
(type (;1;) (func (result i32 i32 i32))) | ||
(type (;2;) (func (result i32 i32 i32 i32))) | ||
(type (;3;) (func (param i32 i32 i32))) | ||
(func $__wbindgen_free (;0;) (type 3) (param i32 i32 i32)) | ||
(func $"result_string multivalue shim" (;1;) (type 2) (result i32 i32 i32 i32)) | ||
(func $"result_i32 multivalue shim" (;2;) (type 1) (result i32 i32 i32)) | ||
(func $"result_void multivalue shim" (;3;) (type 0) (result i32 i32)) | ||
(memory (;0;) 17) | ||
(export "memory" (memory 0)) | ||
(export "result_string" (func $"result_string multivalue shim")) | ||
(export "result_void" (func $"result_void multivalue shim")) | ||
(export "result_i32" (func $"result_i32 multivalue shim")) | ||
(export "__wbindgen_free" (func $__wbindgen_free)) | ||
(@custom "target_features" (after code) "\04+\0amultivalue+\0fmutable-globals+\0freference-types+\08sign-ext") | ||
) | ||
|