diff options
Diffstat (limited to 'js/src/fuzz-tests/testWasm.cpp')
-rw-r--r-- | js/src/fuzz-tests/testWasm.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/js/src/fuzz-tests/testWasm.cpp b/js/src/fuzz-tests/testWasm.cpp index 719c38174a..d7ba0511b4 100644 --- a/js/src/fuzz-tests/testWasm.cpp +++ b/js/src/fuzz-tests/testWasm.cpp @@ -9,6 +9,7 @@ #include "fuzz-tests/tests.h" #include "js/CallAndConstruct.h" +#include "js/Prefs.h" #include "js/PropertyAndElement.h" // JS_Enumerate, JS_GetProperty, JS_GetPropertyById, JS_HasProperty, JS_SetProperty #include "vm/GlobalObject.h" #include "vm/Interpreter.h" @@ -40,13 +41,11 @@ static int testWasmInit(int* argc, char*** argv) { MOZ_CRASH("Wasm is not supported"); } - JS::ContextOptionsRef(gCx) -#define WASM_FEATURE(NAME, LOWER_NAME, STAGE, COMPILE_PRED, COMPILER_PRED, \ - FLAG_PRED, FLAG_FORCE_ON, FLAG_FUZZ_ON, SHELL, PREF) \ - .setWasm##NAME(FLAG_FUZZ_ON) - JS_FOR_WASM_FEATURES(WASM_FEATURE) +#define WASM_FEATURE(NAME, LOWER_NAME, COMPILE_PRED, COMPILER_PRED, FLAG_PRED, \ + FLAG_FORCE_ON, FLAG_FUZZ_ON, PREF) \ + JS::Prefs::setAtStartup_wasm_##PREF(FLAG_FUZZ_ON); + JS_FOR_WASM_FEATURES(WASM_FEATURE) #undef WASM_FEATURE - ; if (!GlobalObject::getOrCreateConstructor(gCx, JSProto_WebAssembly)) { MOZ_CRASH("Failed to initialize wasm engine"); |