Partial revert of [a82e6faaa642] to remove the 'I' alias for 'j' wasm function signature letter. In hindsight, that change seems premature.
FossilOrigin-Name: dcd46af9141f4edf816010923941a76d0edd3f18cfe429c52f599ad2a0d52651
This commit is contained in:
parent
ef9cd12ec4
commit
bdfd7ea03a
@ -615,9 +615,9 @@ const char * sqlite3_wasm_enum_json(void){
|
||||
StructBinder {
|
||||
M(iVersion,"i");
|
||||
M(xClose,"i(p)");
|
||||
M(xRead,"i(ppiI)");
|
||||
M(xWrite,"i(ppiI)");
|
||||
M(xTruncate,"i(pI)");
|
||||
M(xRead,"i(ppij)");
|
||||
M(xWrite,"i(ppij)");
|
||||
M(xTruncate,"i(pj)");
|
||||
M(xSync,"i(pi)");
|
||||
M(xFileSize,"i(pp)");
|
||||
M(xLock,"i(pi)");
|
||||
@ -630,8 +630,8 @@ const char * sqlite3_wasm_enum_json(void){
|
||||
M(xShmLock,"i(piii)");
|
||||
M(xShmBarrier,"v(p)");
|
||||
M(xShmUnmap,"i(pi)");
|
||||
M(xFetch,"i(pIip)");
|
||||
M(xUnfetch,"i(pIp)");
|
||||
M(xFetch,"i(pjip)");
|
||||
M(xUnfetch,"i(pjp)");
|
||||
} _StructBinder;
|
||||
#undef CurrentStruct
|
||||
|
||||
|
@ -389,7 +389,7 @@ self.WhWasmUtilInstaller = function(target){
|
||||
|
||||
- `i` = int32
|
||||
- `p` = int32 ("pointer")
|
||||
- `j` or `I` = int64
|
||||
- `j` = int64
|
||||
- `f` = float32
|
||||
- `d` = float64
|
||||
- `v` = void, only legal for use as the result type
|
||||
@ -417,7 +417,7 @@ self.WhWasmUtilInstaller = function(target){
|
||||
// Map of signature letters to type IR values
|
||||
sigTypes: Object.assign(Object.create(null),{
|
||||
i: 'i32', p: 'i32', P: 'i32', s: 'i32',
|
||||
j: 'i64', I: 'i64', f: 'f32', d: 'f64'
|
||||
j: 'i64', f: 'f32', d: 'f64'
|
||||
}),
|
||||
// Map of type IR values to WASM type code values
|
||||
typeCodes: Object.assign(Object.create(null),{
|
||||
|
@ -123,7 +123,7 @@ self.Jaccwabyt = function StructBinderFactory(config){
|
||||
switch(sigLetter(s)){
|
||||
case 'i': return 'i32';
|
||||
case 'p': case 'P': case 's': return ptrIR;
|
||||
case 'j': case 'I': return 'i64';
|
||||
case 'j': return 'i64';
|
||||
case 'f': return 'float';
|
||||
case 'd': return 'double';
|
||||
}
|
||||
@ -135,7 +135,7 @@ self.Jaccwabyt = function StructBinderFactory(config){
|
||||
switch(sigLetter(s)){
|
||||
case 'i': return 4;
|
||||
case 'p': case 'P': case 's': return ptrSizeof;
|
||||
case 'j': case 'I': return 8;
|
||||
case 'j': return 8;
|
||||
case 'f': return 4 /* C-side floats, not JS-side */;
|
||||
case 'd': return 8;
|
||||
}
|
||||
@ -168,7 +168,7 @@ self.Jaccwabyt = function StructBinderFactory(config){
|
||||
break;
|
||||
}
|
||||
case 'i': return 'getInt32';
|
||||
case 'j': case 'I': return affirmBigIntArray() && 'getBigInt64';
|
||||
case 'j': return affirmBigIntArray() && 'getBigInt64';
|
||||
case 'f': return 'getFloat32';
|
||||
case 'd': return 'getFloat64';
|
||||
}
|
||||
@ -186,7 +186,7 @@ self.Jaccwabyt = function StructBinderFactory(config){
|
||||
break;
|
||||
}
|
||||
case 'i': return 'setInt32';
|
||||
case 'j': case 'I': return affirmBigIntArray() && 'setBigInt64';
|
||||
case 'j': return affirmBigIntArray() && 'setBigInt64';
|
||||
case 'f': return 'setFloat32';
|
||||
case 'd': return 'setFloat64';
|
||||
}
|
||||
@ -200,7 +200,7 @@ self.Jaccwabyt = function StructBinderFactory(config){
|
||||
const sigDVSetWrapper = function(s){
|
||||
switch(sigLetter(s)) {
|
||||
case 'i': case 'f': case 'd': return Number;
|
||||
case 'j': case 'I': return affirmBigIntArray() && BigInt;
|
||||
case 'j': return affirmBigIntArray() && BigInt;
|
||||
case 'p': case 'P': case 's':
|
||||
switch(ptrSizeof){
|
||||
case 4: return Number;
|
||||
@ -361,7 +361,7 @@ self.Jaccwabyt = function StructBinderFactory(config){
|
||||
framework's native format or in Emscripten format.
|
||||
*/
|
||||
const __memberSignature = function f(obj,memberName,emscriptenFormat=false){
|
||||
if(!f._) f._ = (x)=>x.replace(/[^viIpPsjrd]/g,'').replace(/[pPs]/g,'i');
|
||||
if(!f._) f._ = (x)=>x.replace(/[^vipPsjrd]/g,'').replace(/[pPs]/g,'i');
|
||||
const m = __lookupMember(obj.structInfo, memberName, true);
|
||||
return emscriptenFormat ? f._(m.signature) : m.signature;
|
||||
};
|
||||
@ -571,7 +571,7 @@ self.Jaccwabyt = function StructBinderFactory(config){
|
||||
direct reuse in each accessor function. */
|
||||
f._ = {getters: {}, setters: {}, sw:{}};
|
||||
const a = ['i','p','P','s','f','d','v()'];
|
||||
if(bigIntEnabled) a.push('j','I');
|
||||
if(bigIntEnabled) a.push('j');
|
||||
a.forEach(function(v){
|
||||
//const ir = sigIR(v);
|
||||
f._.getters[v] = sigDVGetter(v) /* DataView[MethodName] values for GETTERS */;
|
||||
@ -579,8 +579,8 @@ self.Jaccwabyt = function StructBinderFactory(config){
|
||||
f._.sw[v] = sigDVSetWrapper(v) /* BigInt or Number ctor to wrap around values
|
||||
for conversion */;
|
||||
});
|
||||
const rxSig1 = /^[iIpPsjfd]$/,
|
||||
rxSig2 = /^[viIpPsjfd]\([iIpPsjfd]*\)$/;
|
||||
const rxSig1 = /^[ipPsjfd]$/,
|
||||
rxSig2 = /^[vipPsjfd]\([ipPsjfd]*\)$/;
|
||||
f.sigCheck = function(obj, name, key,sig){
|
||||
if(Object.prototype.hasOwnProperty.call(obj, key)){
|
||||
toss(obj.structName,'already has a property named',key+'.');
|
||||
|
@ -275,10 +275,10 @@ supported letters are:
|
||||
|
||||
- **`v`** = `void` (only used as return type for function pointer members)
|
||||
- **`i`** = `int32` (4 bytes)
|
||||
- **`j`** or **`I`** = `int64` (8 bytes) is only really usable if this
|
||||
code is built with BigInt support (e.g. using the Emscripten
|
||||
`-sWASM_BIGINT` build flag). Without that, this API may throw when
|
||||
encountering this signature entry.
|
||||
- **`j`** = `int64` (8 bytes) is only really usable if this code is built
|
||||
with BigInt support (e.g. using the Emscripten `-sWASM_BIGINT` build
|
||||
flag). Without that, this API may throw when encountering the `j`
|
||||
signature entry.
|
||||
- **`f`** = `float` (4 bytes)
|
||||
- **`d`** = `double` (8 bytes)
|
||||
- **`p`** = `int32` (but see below!)
|
||||
|
18
manifest
18
manifest
@ -1,5 +1,5 @@
|
||||
C Minor\sJS\sAPI\stweaks\sprompted\sby\sdocumenting\sthem.
|
||||
D 2022-10-03T08:21:06.951
|
||||
C Partial\srevert\sof\s[a82e6faaa642]\sto\sremove\sthe\s'I'\salias\sfor\s'j'\swasm\sfunction\ssignature\sletter.\sIn\shindsight,\sthat\schange\sseems\spremature.
|
||||
D 2022-10-03T08:30:22.681
|
||||
F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1
|
||||
F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea
|
||||
F LICENSE.md df5091916dbb40e6e9686186587125e1b2ff51f022cc334e886c19a0e9982724
|
||||
@ -491,13 +491,13 @@ F ext/wasm/api/sqlite3-api-opfs.js 1b097808b7b081b0f0700cf97d49ef19760e401706168
|
||||
F ext/wasm/api/sqlite3-api-prologue.js b827e2353799b54fffaa9577f51ebf08b8dedc58dcabe344c73be977235da227
|
||||
F ext/wasm/api/sqlite3-api-worker1.js 7f4f46cb6b512a48572d7567233896e6a9c46570c44bdc3d13419730c7c221c8
|
||||
F ext/wasm/api/sqlite3-wasi.h 25356084cfe0d40458a902afb465df8c21fc4152c1d0a59b563a3fba59a068f9
|
||||
F ext/wasm/api/sqlite3-wasm.c 074c1c80b52bd808baf1228adc3336b3aeb2649579d041fc199ead747b5892aa
|
||||
F ext/wasm/api/sqlite3-wasm.c 2a0f9e4bf1b141a787918951360601128d6a0a190a31a8e5cfe237c99fa640c6
|
||||
F ext/wasm/batch-runner.html c363032aba7a525920f61f8be112a29459f73f07e46f0ba3b7730081a617826e
|
||||
F ext/wasm/batch-runner.js ce92650a6681586c89bef26ceae96674a55ca5a9727815202ca62e1a00ff5015
|
||||
F ext/wasm/common/SqliteTestUtil.js 647bf014bd30bdd870a7e9001e251d12fc1c9ec9ce176a1004b838a4b33c5c05
|
||||
F ext/wasm/common/emscripten.css 3d253a6fdb8983a2ac983855bfbdd4b6fa1ff267c28d69513dd6ef1f289ada3f
|
||||
F ext/wasm/common/testing.css 3a5143699c2b73a85b962271e1a9b3241b30d90e30d895e4f55665e648572962
|
||||
F ext/wasm/common/whwasmutil.js 0ea155094dc9b18ee97a37b7b26e0601fee4822f5f1d2f5853a57542b45598d9
|
||||
F ext/wasm/common/whwasmutil.js 8a0557f2b8b0e2c2671072e9d8869c1591db59995de81eb8eca47d6c5d8457d9
|
||||
F ext/wasm/demo-123-worker.html e419b66495d209b5211ec64903b4cfb3ca7df20d652b41fcd28bf018a773234f
|
||||
F ext/wasm/demo-123.html aa281d33b7eefa755f3122b7b5a18f39a42dc5fb69c8879171bf14b4c37c4ec4
|
||||
F ext/wasm/demo-123.js 9fbc5cd3af842d361e9f8353ae4af9f471c2b2517e55446474406620485b9ee6
|
||||
@ -509,8 +509,8 @@ F ext/wasm/fiddle/fiddle-worker.js ebf6e95fe031738cd9f79d1ccdf6d80640a2884a43f70
|
||||
F ext/wasm/fiddle/fiddle.html 5daf54e8f3d7777cbb1ca4f93affe28858dbfff25841cb4ab81d694efed28ec2
|
||||
F ext/wasm/fiddle/fiddle.js 974b995119ac443685d7d94d3b3c58c6a36540e9eb3fed7069d5653284071715
|
||||
F ext/wasm/index.html 63b370619e4f849ac76f1baed435c05edc29dbb6795bc7c1c935561ff667dd27
|
||||
F ext/wasm/jaccwabyt/jaccwabyt.js db2c75f12426760eb921c281eef7fd139f23cd61d16d8638689ee162e90ef2f6
|
||||
F ext/wasm/jaccwabyt/jaccwabyt.md 48088122e9d23b1b385bb7bcf48a2d83f926b470d6928b6b3f9b41c2de94830c
|
||||
F ext/wasm/jaccwabyt/jaccwabyt.js 0d7f32817456a0f3937fcfd934afeb32154ca33580ab264dab6c285e6dbbd215
|
||||
F ext/wasm/jaccwabyt/jaccwabyt.md 9aa6951b529a8b29f578ec8f0355713c39584c92cf1708f63ba0cf917cb5b68e
|
||||
F ext/wasm/jaccwabyt/jaccwabyt_test.c 39e4b865a33548f943e2eb9dd0dc8d619a80de05d5300668e9960fff30d0d36f
|
||||
F ext/wasm/jaccwabyt/jaccwabyt_test.exports 5ff001ef975c426ffe88d7d8a6e96ec725e568d2c2307c416902059339c06f19
|
||||
F ext/wasm/scratchpad-wasmfs-main.html 20cf6f1a8f368e70d01e8c17200e3eaa90f1c8e1029186d836d14b83845fbe06
|
||||
@ -2029,8 +2029,8 @@ F vsixtest/vsixtest.tcl 6a9a6ab600c25a91a7acc6293828957a386a8a93
|
||||
F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc
|
||||
F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e
|
||||
F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0
|
||||
P 10ab77af952abf09f93f342a9d07a3b133f2c4c0a3588df3390cd3a923cafae4
|
||||
R 12182f4e06ca014e75dafbecebb22765
|
||||
P a82e6faaa642b09d241232c4daa67134d4dfa24bf3ca3725740346ca5269b381
|
||||
R 1cdb3ca834e236e54389a61ca1f0d059
|
||||
U stephan
|
||||
Z 53ad4d279050a64639e6682eb9a83efd
|
||||
Z ee5810e1e70af12e58974dd2bc072e0d
|
||||
# Remove this line to create a well-formed Fossil manifest.
|
||||
|
@ -1 +1 @@
|
||||
a82e6faaa642b09d241232c4daa67134d4dfa24bf3ca3725740346ca5269b381
|
||||
dcd46af9141f4edf816010923941a76d0edd3f18cfe429c52f599ad2a0d52651
|
Loading…
Reference in New Issue
Block a user