From d9fbc48daac43b8d16277812a18aa4504cb060b2 Mon Sep 17 00:00:00 2001 From: Sendil Kumar Date: Tue, 14 Aug 2018 19:38:33 +0200 Subject: [PATCH] js-sys: Add extends attributes for js_sys::Float32Array --- crates/js-sys/src/lib.rs | 2 +- crates/js-sys/tests/wasm/TypedArray.rs | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/crates/js-sys/src/lib.rs b/crates/js-sys/src/lib.rs index f8aff6b1..c913a59f 100644 --- a/crates/js-sys/src/lib.rs +++ b/crates/js-sys/src/lib.rs @@ -684,7 +684,7 @@ extern "C" { #[wasm_bindgen] extern "C" { // TODO Uncomment this once TypedArray is added: - // #[wasm_bindgen(extends = Object, extends = TypedArray)] + #[wasm_bindgen(extends = Object)] #[derive(Clone, Debug)] pub type Float32Array; diff --git a/crates/js-sys/tests/wasm/TypedArray.rs b/crates/js-sys/tests/wasm/TypedArray.rs index 751ec1bf..4a99cb2e 100644 --- a/crates/js-sys/tests/wasm/TypedArray.rs +++ b/crates/js-sys/tests/wasm/TypedArray.rs @@ -12,6 +12,7 @@ macro_rules! each { $m!(Int8Array); $m!(Int16Array); $m!(Int32Array); + $m!(Float32Array); ) }