diff options
author | 2023-10-16 21:22:43 -0700 | |
---|---|---|
committer | 2023-10-16 21:22:43 -0700 | |
commit | 98d19fa6244384f7e17998b5420d724481ed3835 (patch) | |
tree | 3061ccab41196daf4194ecc385961b121f2ec06d /src/bun.js/bindings/sqlite/JSSQLStatement.cpp | |
parent | a3958190e8f106adca7fbf4ba2605056cb22aced (diff) | |
download | bun-98d19fa6244384f7e17998b5420d724481ed3835.tar.gz bun-98d19fa6244384f7e17998b5420d724481ed3835.tar.zst bun-98d19fa6244384f7e17998b5420d724481ed3835.zip |
fix(runtime): make some things more stable (partial jsc debug build) (#5881)
* make our debug assertions work
* install bun-webkit-debug
* more progress
* ok
* progress...
* more debug build stuff
* ok
* a
* asdfghjkl
* fix(runtime): fix bad assertion failure in JSBufferList
* ok
* stuff
* upgrade webkit
* Update src/bun.js/bindings/JSDOMWrapperCache.h
Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
* fix message for colin's changes
* okay
* fix cjs prototype
* implement mainModule
* i think this fixes it all
---------
Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
Diffstat (limited to 'src/bun.js/bindings/sqlite/JSSQLStatement.cpp')
-rw-r--r-- | src/bun.js/bindings/sqlite/JSSQLStatement.cpp | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/src/bun.js/bindings/sqlite/JSSQLStatement.cpp b/src/bun.js/bindings/sqlite/JSSQLStatement.cpp index cad20df6f..2ce4cc9a6 100644 --- a/src/bun.js/bindings/sqlite/JSSQLStatement.cpp +++ b/src/bun.js/bindings/sqlite/JSSQLStatement.cpp @@ -188,7 +188,7 @@ public: JSC::JSValue rebind(JSGlobalObject* globalObject, JSC::JSValue values, bool clone); static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype) { - return JSC::Structure::create(vm, globalObject, prototype, JSC::TypeInfo(JSC::ObjectType, StructureFlags), info()); + return JSC::Structure::create(vm, globalObject, prototype, JSC::TypeInfo(JSC::JSFunctionType, StructureFlags), info()); } bool need_update() { return version_db->version.load() != version; } @@ -341,10 +341,6 @@ void JSSQLStatement::destroy(JSC::JSCell* cell) thisObject->stmt = nullptr; } -void JSSQLStatementConstructor::destroy(JSC::JSCell* cell) -{ -} - static inline bool rebindValue(JSC::JSGlobalObject* lexicalGlobalObject, sqlite3_stmt* stmt, int i, JSC::JSValue value, JSC::ThrowScope& scope, bool clone) { #define CHECK_BIND(param) \ @@ -695,7 +691,7 @@ JSC_DEFINE_HOST_FUNCTION(jsSQLStatementLoadExtensionFunction, (JSC::JSGlobalObje return JSValue::encode(JSC::jsUndefined()); } - if(sqlite3_compileoption_used("SQLITE_OMIT_LOAD_EXTENSION")) { + if (sqlite3_compileoption_used("SQLITE_OMIT_LOAD_EXTENSION")) { throwException(lexicalGlobalObject, scope, createError(lexicalGlobalObject, "This build of sqlite3 does not support dynamic extension loading"_s)); return JSValue::encode(JSC::jsUndefined()); } @@ -1064,7 +1060,7 @@ static const HashTableValue JSSQLStatementConstructorTableValues[] = { { "deserialize"_s, static_cast<unsigned>(JSC::PropertyAttribute::Function), NoIntrinsic, { HashTableValue::NativeFunctionType, jsSQLStatementDeserialize, 2 } }, }; -const ClassInfo JSSQLStatementConstructor::s_info = { "SQLStatement"_s, nullptr, nullptr, nullptr, CREATE_METHOD_TABLE(JSSQLStatementConstructor) }; +const ClassInfo JSSQLStatementConstructor::s_info = { "SQLStatement"_s, &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSSQLStatementConstructor) }; void JSSQLStatementConstructor::finishCreation(VM& vm) { @@ -1636,7 +1632,7 @@ JSC_DEFINE_HOST_FUNCTION(jsSQLStatementFunctionFinalize, (JSC::JSGlobalObject * RELEASE_AND_RETURN(scope, JSValue::encode(jsUndefined())); } -const ClassInfo JSSQLStatement::s_info = { "SQLStatement"_s, nullptr, nullptr, nullptr, CREATE_METHOD_TABLE(JSSQLStatement) }; +const ClassInfo JSSQLStatement::s_info = { "SQLStatement"_s, &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSSQLStatement) }; /* Hash table for prototype */ static const HashTableValue JSSQLStatementTableValues[] = { |