diff --git a/test/test_core.py b/test/test_core.py index a0ca156aca1f2..a2faff75a0c4d 100644 --- a/test/test_core.py +++ b/test/test_core.py @@ -1720,6 +1720,12 @@ def clear_all_relevant_settings(self): self.assert_fail([EMCC, test_file('hello_world.cpp')] + self.get_cflags(), expected) clear_all_relevant_settings(self) + expected = "error: cannot use 'throw' with exceptions disabled" + self.assert_fail([EMCC, test_file('core/test_exceptions.cpp'), '-fwasm-exceptions', '-fno-exceptions'] + self.get_cflags(), expected) + clear_all_relevant_settings(self) + self.assert_fail([EMCC, test_file('core/test_exceptions.cpp'), '-fno-exceptions', '-fwasm-exceptions'] + self.get_cflags(), expected) + clear_all_relevant_settings(self) + # Marked as impure since the WASI reactor modules (modules without main) # are not yet supported by the wasm engines we test against. @also_with_standalone_wasm(impure=True) diff --git a/tools/cmdline.py b/tools/cmdline.py index 8ce4faf2a7a12..030ba2b418ff0 100644 --- a/tools/cmdline.py +++ b/tools/cmdline.py @@ -508,7 +508,6 @@ def consume_arg_file(): elif arg == '-fno-exceptions': settings.DISABLE_EXCEPTION_CATCHING = 1 settings.DISABLE_EXCEPTION_THROWING = 1 - settings.WASM_EXCEPTIONS = 0 elif arg == '-mbulk-memory': feature_matrix.enable_feature(feature_matrix.Feature.BULK_MEMORY, '-mbulk-memory',