Logo
Explore Help
Sign In
fluencelabs/wasm-bindgen
1
0
Fork 0
You've already forked wasm-bindgen
mirror of https://github.com/fluencelabs/wasm-bindgen synced 2025-06-13 21:11:22 +00:00
Code Issues Projects Releases Wiki Activity
Files
8cb792474cedbfb8d2e7e3c1c38fc2df4cdabca1
wasm-bindgen/crates/webidl-tests/array_buffer.rs

12 lines
273 B
Rust
Raw Normal View History

Add WebIDL support for the `ArrayBuffer` type Should help enable a slew of new bindings as well.
2018-08-04 13:51:22 -07:00
use wasm_bindgen_test::*;
include!(concat!(env!("OUT_DIR"), "/array_buffer.rs"));
#[wasm_bindgen_test]
fn take_and_return_a_bunch_of_slices() {
let f = ArrayBufferTest::new().unwrap();
let x = f.get_buffer();
f.set_buffer(None);
Implement support for WebIDL `Callback` types This commit adds support for the WebIDL `Callback` type by translating all callbacks to the `js_sys::Function` type. This will enable passing raw JS values into callbacks as well as Rust valus using the `Closure` type. This commit doesn't currently implement "callback interfaces" in WebIDL, that's left for a follow-up commit.
2018-09-06 16:18:24 -07:00
f.set_buffer(Some(&x));
Add WebIDL support for the `ArrayBuffer` type Should help enable a slew of new bindings as well.
2018-08-04 13:51:22 -07:00
}
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.24.0 Page: 95ms Template: 3ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API