Add a DOM gadget for Spectre testing
[WebKit-https.git] / Source / WebCore / page / RuntimeEnabledFeatures.cpp
index def1188..8d52c44 100644 (file)
@@ -33,6 +33,7 @@
 #include "RuntimeEnabledFeatures.h"
 
 #include "MediaPlayer.h"
+#include <JavaScriptCore/Options.h>
 #include <wtf/NeverDestroyed.h>
 
 namespace WebCore {
@@ -51,6 +52,11 @@ RuntimeEnabledFeatures& RuntimeEnabledFeatures::sharedFeatures()
     return runtimeEnabledFeatures;
 }
 
+bool RuntimeEnabledFeatures::spectreGadgetsEnabled() const
+{
+    return JSC::Options::enableSpectreGadgets();
+}
+
 #if ENABLE(VIDEO)
 bool RuntimeEnabledFeatures::audioEnabled() const
 {