From afa7bddc9640c845895d8de3cecdc2f6ec63e4f0 Mon Sep 17 00:00:00 2001 From: Martok Date: Sat, 8 Apr 2023 04:47:37 +0200 Subject: [PATCH] Issue #2142 - Add internal option for fields, but always true This allows us to perform bisects on the following commits without causing runtime issues. Based-on: m-c 1529758 --- js/src/jsapi.cpp | 1 + js/src/jsapi.h | 2 ++ 2 files changed, 3 insertions(+) diff --git a/js/src/jsapi.cpp b/js/src/jsapi.cpp index c0bcad81ef..98a940904d 100644 --- a/js/src/jsapi.cpp +++ b/js/src/jsapi.cpp @@ -3873,6 +3873,7 @@ JS::TransitiveCompileOptions::copyPODTransitiveOptions(const TransitiveCompileOp forceAsync = rhs.forceAsync; installedFile = rhs.installedFile; sourceIsLazy = rhs.sourceIsLazy; + fieldsEnabledOption = rhs.fieldsEnabledOption; introductionType = rhs.introductionType; introductionLineno = rhs.introductionLineno; introductionOffset = rhs.introductionOffset; diff --git a/js/src/jsapi.h b/js/src/jsapi.h index a6a5429cf5..4640ab0b50 100644 --- a/js/src/jsapi.h +++ b/js/src/jsapi.h @@ -3820,6 +3820,7 @@ class JS_FRIEND_API(TransitiveCompileOptions) forceAsync(false), installedFile(false), sourceIsLazy(false), + fieldsEnabledOption(true), introductionType(nullptr), introductionLineno(0), introductionOffset(0), @@ -3855,6 +3856,7 @@ class JS_FRIEND_API(TransitiveCompileOptions) bool forceAsync; bool installedFile; // 'true' iff pre-compiling js file in packaged app bool sourceIsLazy; + bool fieldsEnabledOption; // |introductionType| is a statically allocated C string: // one of "eval", "Function", or "GeneratorFunction".