mirror of
https://github.com/sqlite/sqlite.git
synced 2025-07-29 08:01:23 +03:00
wasm: change StructBinder signature for sqlite3_file::pMethods from 'P' to 'p' to eliminate an unnecessary and inconsistent level of magic.
FossilOrigin-Name: 85f2e877e53899860af4dc6630044b471a9c7c82faba1f4e1e60ae991460b943
This commit is contained in:
@ -503,7 +503,7 @@ const char * sqlite3_wasm_enum_json(void){
|
||||
|
||||
#define CurrentStruct sqlite3_file
|
||||
StructBinder {
|
||||
M(pMethods,"P");
|
||||
M(pMethods,"p");
|
||||
} _StructBinder;
|
||||
#undef CurrentStruct
|
||||
|
||||
|
@ -717,17 +717,14 @@
|
||||
//log("sfile",sfile,sfile.constructor.prototype);
|
||||
T.assert(0===sfile.$pMethods).assert(iom.pointer > 0);
|
||||
//log("iom",iom);
|
||||
/** Some of the following tests require that pMethods has a
|
||||
signature of "P", as opposed to "p". */
|
||||
sfile.$pMethods = iom;
|
||||
T.assert(iom === sfile.$pMethods);
|
||||
sfile.$pMethods = iom.pointer;
|
||||
T.assert(iom === sfile.$pMethods)
|
||||
T.assert(iom.pointer === sfile.$pMethods)
|
||||
.assert(IOM.resolveToInstance(iom))
|
||||
.assert(undefined ===IOM.resolveToInstance(sfile))
|
||||
.mustThrow(()=>IOM.resolveToInstance(0,true))
|
||||
.assert(S3F.resolveToInstance(sfile.pointer))
|
||||
.assert(undefined===S3F.resolveToInstance(iom));
|
||||
.assert(undefined===S3F.resolveToInstance(iom))
|
||||
.assert(iom===IOM.resolveToInstance(sfile.$pMethods));
|
||||
T.assert(0===iom.$iVersion);
|
||||
installIOMethods(iom);
|
||||
T.assert(1===iom.$iVersion);
|
||||
|
Reference in New Issue
Block a user