From c0f2773c4eece44d39b576e9a4bcc928ae76b1db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Flemstr=C3=B6m?= Date: Sun, 11 Feb 2018 11:11:41 +0100 Subject: [PATCH] Don't panic on unsupported exports It's most likely safe for us to skip exports that we don't yet support. Doing nothing will at least not hurt in those cases. --- crates/wasm-bindgen-cli-support/src/wasm2es6js.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/crates/wasm-bindgen-cli-support/src/wasm2es6js.rs b/crates/wasm-bindgen-cli-support/src/wasm2es6js.rs index f0801b54..6379a907 100644 --- a/crates/wasm-bindgen-cli-support/src/wasm2es6js.rs +++ b/crates/wasm-bindgen-cli-support/src/wasm2es6js.rs @@ -57,10 +57,10 @@ impl Output { continue } Internal::Table(_) => { - panic!("wasm exports a table which isn't supported yet"); + continue } Internal::Global(_) => { - panic!("wasm exports globals which aren't supported yet"); + continue } }; @@ -145,10 +145,10 @@ impl Output { continue } Internal::Table(_) => { - panic!("wasm exports a table which isn't supported yet"); + continue } Internal::Global(_) => { - panic!("wasm exports globals which aren't supported yet"); + continue } };