From 97cceb47b9fb14fbf8cb45a28038934b6416e8ef Mon Sep 17 00:00:00 2001 From: Jarred Sumner Date: Sun, 8 May 2022 01:12:13 -0700 Subject: Upgrade WebKit --- .../jsc/bindings/webcore/JSCustomEvent.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'src/javascript/jsc/bindings/webcore/JSCustomEvent.cpp') diff --git a/src/javascript/jsc/bindings/webcore/JSCustomEvent.cpp b/src/javascript/jsc/bindings/webcore/JSCustomEvent.cpp index 35f51ba4b..843211d8d 100644 --- a/src/javascript/jsc/bindings/webcore/JSCustomEvent.cpp +++ b/src/javascript/jsc/bindings/webcore/JSCustomEvent.cpp @@ -66,7 +66,7 @@ template<> CustomEvent::Init convertDictionary(JSGlobalObject if (isNullOrUndefined) bubblesValue = jsUndefined(); else { - bubblesValue = object->get(&lexicalGlobalObject, Identifier::fromString(vm, "bubbles")); + bubblesValue = object->get(&lexicalGlobalObject, Identifier::fromString(vm, "bubbles"_s)); RETURN_IF_EXCEPTION(throwScope, {}); } if (!bubblesValue.isUndefined()) { @@ -78,7 +78,7 @@ template<> CustomEvent::Init convertDictionary(JSGlobalObject if (isNullOrUndefined) cancelableValue = jsUndefined(); else { - cancelableValue = object->get(&lexicalGlobalObject, Identifier::fromString(vm, "cancelable")); + cancelableValue = object->get(&lexicalGlobalObject, Identifier::fromString(vm, "cancelable"_s)); RETURN_IF_EXCEPTION(throwScope, {}); } if (!cancelableValue.isUndefined()) { @@ -90,7 +90,7 @@ template<> CustomEvent::Init convertDictionary(JSGlobalObject if (isNullOrUndefined) composedValue = jsUndefined(); else { - composedValue = object->get(&lexicalGlobalObject, Identifier::fromString(vm, "composed")); + composedValue = object->get(&lexicalGlobalObject, Identifier::fromString(vm, "composed"_s)); RETURN_IF_EXCEPTION(throwScope, {}); } if (!composedValue.isUndefined()) { @@ -102,7 +102,7 @@ template<> CustomEvent::Init convertDictionary(JSGlobalObject if (isNullOrUndefined) detailValue = jsUndefined(); else { - detailValue = object->get(&lexicalGlobalObject, Identifier::fromString(vm, "detail")); + detailValue = object->get(&lexicalGlobalObject, Identifier::fromString(vm, "detail"_s)); RETURN_IF_EXCEPTION(throwScope, {}); } if (!detailValue.isUndefined()) { @@ -165,12 +165,12 @@ template<> EncodedJSValue JSC_HOST_CALL_ATTRIBUTES JSCustomEventDOMConstructor:: if (UNLIKELY(callFrame->argumentCount() < 1)) return throwVMError(lexicalGlobalObject, throwScope, createNotEnoughArgumentsError(lexicalGlobalObject)); EnsureStillAliveScope argument0 = callFrame->uncheckedArgument(0); - auto type = convert(*lexicalGlobalObject, argument0.value()); + auto type = convert>(*lexicalGlobalObject, argument0.value()); RETURN_IF_EXCEPTION(throwScope, encodedJSValue()); EnsureStillAliveScope argument1 = callFrame->argument(1); auto eventInitDict = convert>(*lexicalGlobalObject, argument1.value()); RETURN_IF_EXCEPTION(throwScope, encodedJSValue()); - auto object = CustomEvent::create(WTFMove(type), WTFMove(eventInitDict)); + auto object = CustomEvent::create(type, WTFMove(eventInitDict)); if constexpr (IsExceptionOr) RETURN_IF_EXCEPTION(throwScope, {}); static_assert(TypeOrExceptionOrUnderlyingType::isRef); @@ -226,7 +226,7 @@ JSCustomEvent::JSCustomEvent(Structure* structure, JSDOMGlobalObject& globalObje void JSCustomEvent::finishCreation(VM& vm) { Base::finishCreation(vm); - ASSERT(inherits(vm, info())); + ASSERT(inherits(info())); // static_assert(!std::is_base_of::value, "Interface is not marked as [ActiveDOMObject] even though implementation class subclasses ActiveDOMObject."); } @@ -250,7 +250,7 @@ JSC_DEFINE_CUSTOM_GETTER(jsCustomEventConstructor, (JSGlobalObject * lexicalGlob { VM& vm = JSC::getVM(lexicalGlobalObject); auto throwScope = DECLARE_THROW_SCOPE(vm); - auto* prototype = jsDynamicCast(vm, JSValue::decode(thisValue)); + auto* prototype = jsDynamicCast(JSValue::decode(thisValue)); if (UNLIKELY(!prototype)) return throwVMTypeError(lexicalGlobalObject, throwScope); return JSValue::encode(JSCustomEvent::getConstructor(JSC::getVM(lexicalGlobalObject), prototype->globalObject())); @@ -277,7 +277,7 @@ static inline JSC::EncodedJSValue jsCustomEventPrototypeFunction_initCustomEvent if (UNLIKELY(callFrame->argumentCount() < 1)) return throwVMError(lexicalGlobalObject, throwScope, createNotEnoughArgumentsError(lexicalGlobalObject)); EnsureStillAliveScope argument0 = callFrame->uncheckedArgument(0); - auto type = convert(*lexicalGlobalObject, argument0.value()); + auto type = convert>(*lexicalGlobalObject, argument0.value()); RETURN_IF_EXCEPTION(throwScope, encodedJSValue()); EnsureStillAliveScope argument1 = callFrame->argument(1); auto bubbles = convert(*lexicalGlobalObject, argument1.value()); @@ -288,7 +288,7 @@ static inline JSC::EncodedJSValue jsCustomEventPrototypeFunction_initCustomEvent EnsureStillAliveScope argument3 = callFrame->argument(3); auto detail = argument3.value().isUndefined() ? jsNull() : convert(*lexicalGlobalObject, argument3.value()); RETURN_IF_EXCEPTION(throwScope, encodedJSValue()); - RELEASE_AND_RETURN(throwScope, JSValue::encode(toJS(*lexicalGlobalObject, throwScope, [&]() -> decltype(auto) { return impl.initCustomEvent(WTFMove(type), WTFMove(bubbles), WTFMove(cancelable), WTFMove(detail)); }))); + RELEASE_AND_RETURN(throwScope, JSValue::encode(toJS(*lexicalGlobalObject, throwScope, [&]() -> decltype(auto) { return impl.initCustomEvent(type, WTFMove(bubbles), WTFMove(cancelable), WTFMove(detail)); }))); } JSC_DEFINE_HOST_FUNCTION(jsCustomEventPrototypeFunction_initCustomEvent, (JSGlobalObject * lexicalGlobalObject, CallFrame* callFrame)) -- cgit v1.2.3