Update WebKit (#1165)

* Update WebKit

* Fix `DataView` and non-8 bit sized typed arrays with TextDecoder

* New WebKit

Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
This commit is contained in:
Jarred Sumner
2022-08-27 23:46:05 -07:00
committed by GitHub
parent 8b3afa5831
commit af5c4dedca
67 changed files with 1208 additions and 1081 deletions

View File

@@ -39,13 +39,11 @@
#include <wtf/GetPtr.h>
#include <wtf/PointerPreparations.h>
namespace WebCore {
using namespace JSC;
// Functions
// Attributes
static JSC_DECLARE_CUSTOM_GETTER(jsWritableStreamDefaultControllerConstructor);
@@ -108,10 +106,9 @@ template<> FunctionExecutable* JSWritableStreamDefaultControllerDOMConstructor::
/* Hash table for prototype */
static const HashTableValue JSWritableStreamDefaultControllerPrototypeTableValues[] =
{
{ "constructor"_s, static_cast<unsigned>(JSC::PropertyAttribute::DontEnum), NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsWritableStreamDefaultControllerConstructor), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } },
{ "error"_s, static_cast<unsigned>(JSC::PropertyAttribute::Builtin), NoIntrinsic, { (intptr_t)static_cast<BuiltinGenerator>(writableStreamDefaultControllerErrorCodeGenerator), (intptr_t) (0) } },
static const HashTableValue JSWritableStreamDefaultControllerPrototypeTableValues[] = {
{ "constructor"_s, static_cast<unsigned>(JSC::PropertyAttribute::DontEnum), NoIntrinsic, { HashTableValue::GetterSetterType, jsWritableStreamDefaultControllerConstructor, 0 } },
{ "error"_s, static_cast<unsigned>(JSC::PropertyAttribute::Builtin), NoIntrinsic, { HashTableValue::BuiltinGeneratorType, writableStreamDefaultControllerErrorCodeGenerator, 0 } },
};
const ClassInfo JSWritableStreamDefaultControllerPrototype::s_info = { "WritableStreamDefaultController"_s, &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSWritableStreamDefaultControllerPrototype) };
@@ -126,13 +123,14 @@ void JSWritableStreamDefaultControllerPrototype::finishCreation(VM& vm)
const ClassInfo JSWritableStreamDefaultController::s_info = { "WritableStreamDefaultController"_s, &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSWritableStreamDefaultController) };
JSWritableStreamDefaultController::JSWritableStreamDefaultController(Structure* structure, JSDOMGlobalObject& globalObject)
: JSDOMObject(structure, globalObject) { }
: JSDOMObject(structure, globalObject)
{
}
void JSWritableStreamDefaultController::finishCreation(VM& vm)
{
Base::finishCreation(vm);
ASSERT(inherits(info()));
}
JSObject* JSWritableStreamDefaultController::createPrototype(VM& vm, JSDOMGlobalObject& globalObject)
@@ -156,7 +154,7 @@ void JSWritableStreamDefaultController::destroy(JSC::JSCell* cell)
thisObject->JSWritableStreamDefaultController::~JSWritableStreamDefaultController();
}
JSC_DEFINE_CUSTOM_GETTER(jsWritableStreamDefaultControllerConstructor, (JSGlobalObject* lexicalGlobalObject, EncodedJSValue thisValue, PropertyName))
JSC_DEFINE_CUSTOM_GETTER(jsWritableStreamDefaultControllerConstructor, (JSGlobalObject * lexicalGlobalObject, EncodedJSValue thisValue, PropertyName))
{
VM& vm = JSC::getVM(lexicalGlobalObject);
auto throwScope = DECLARE_THROW_SCOPE(vm);
@@ -168,13 +166,12 @@ JSC_DEFINE_CUSTOM_GETTER(jsWritableStreamDefaultControllerConstructor, (JSGlobal
JSC::GCClient::IsoSubspace* JSWritableStreamDefaultController::subspaceForImpl(JSC::VM& vm)
{
return WebCore::subspaceForImpl<JSWritableStreamDefaultController, UseCustomHeapCellType::No>(vm,
[] (auto& spaces) { return spaces.m_clientSubspaceForWritableStreamDefaultController.get(); },
[] (auto& spaces, auto&& space) { spaces.m_clientSubspaceForWritableStreamDefaultController = WTFMove(space); },
[] (auto& spaces) { return spaces.m_subspaceForWritableStreamDefaultController.get(); },
[] (auto& spaces, auto&& space) { spaces.m_subspaceForWritableStreamDefaultController = WTFMove(space); }
);
return WebCore::subspaceForImpl<JSWritableStreamDefaultController, UseCustomHeapCellType::No>(
vm,
[](auto& spaces) { return spaces.m_clientSubspaceForWritableStreamDefaultController.get(); },
[](auto& spaces, auto&& space) { spaces.m_clientSubspaceForWritableStreamDefaultController = WTFMove(space); },
[](auto& spaces) { return spaces.m_subspaceForWritableStreamDefaultController.get(); },
[](auto& spaces, auto&& space) { spaces.m_subspaceForWritableStreamDefaultController = WTFMove(space); });
}
}