mirror of
https://github.com/rustwasm/wasm-bindgen.git
synced 2024-11-25 09:02:46 +03:00
webidl: use JSValue::from in IntoWasmAbi
for enums
This commit is contained in:
parent
c56b1b0189
commit
6608828d72
@ -645,9 +645,7 @@ impl ToTokens for ast::ImportEnum {
|
|||||||
::wasm_bindgen::convert::IntoWasmAbi>::Abi;
|
::wasm_bindgen::convert::IntoWasmAbi>::Abi;
|
||||||
|
|
||||||
fn into_abi(self, extra: &mut ::wasm_bindgen::convert::Stack) -> Self::Abi {
|
fn into_abi(self, extra: &mut ::wasm_bindgen::convert::Stack) -> Self::Abi {
|
||||||
match self {
|
::wasm_bindgen::JsValue::from(self).into_abi(extra)
|
||||||
#(#variant_paths_ref => ::wasm_bindgen::JsValue::from_str(#variant_strings).into_abi(extra),)*
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user