From 40a355a42d4a9444dc753c04c6608dade2f06a23 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Fri, 19 Apr 2024 03:13:27 +0200 Subject: Adding upstream version 125.0.1. Signed-off-by: Daniel Baumann --- js/src/fuzz-tests/testWasm.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'js/src/fuzz-tests') 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"); -- cgit v1.2.3