/**
Helper for string:flexible conversions which require a
byte-length counterpart argument. Passed a value and its
- ostensible length, this function returns [V,N], where V
- is either v or a transformed copy of v and N is either n,
- -1, or the byte length of v (if it's a byte array).
+ ostensible length, this function returns [V,N], where V is
+ either v or a transformed copy of v and N is either n, -1, or
+ the byte length of v (if it's a byte array or ArrayBuffer).
*/
const __flexiString = (v,n)=>{
if('string'===typeof v){
n = -1;
}else if(util.isSQLableTypedArray(v)){
n = v.byteLength;
- v = util.typedArrayToString(v);
+ v = util.typedArrayToString(
+ (v instanceof ArrayBuffer) ? new Uint8Array(v) : v
+ );
}else if(Array.isArray(v)){
v = v.join("");
n = -1;
terminated with a 0 byte.
In usage (1), the 2nd argument must be of type string,
- Uint8Array, or Int8Array (either of which is assumed to
- hold SQL). If it is, this function assumes case (1) and
+ Uint8Array, Int8Array, or ArrayBuffer (all of which are assumed
+ to hold SQL). If it is, this function assumes case (1) and
calls the underyling C function with the equivalent of:
(pDb, sqlAsString, -1, prepFlags, ppStmt, null)
-C Correct\ssome\sinternal-use\sJS\sdocs\sand\supdate\sthe\s'string:flexible'\stype\sconversion\sto\saccept\san\sArrayBuffer\s(as\sit\swas\srecently\sdocumented\sto).
-D 2022-12-26T14:55:00.015
+C Document\ssqlite3.capi.sqlite3_prepare_v3()\sas\saccepting\san\sArrayBuffer\sand\sensure\sthat\sit\scan.
+D 2022-12-26T15:08:48.274
F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1
F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea
F LICENSE.md df5091916dbb40e6e9686186587125e1b2ff51f022cc334e886c19a0e9982724
F ext/wasm/api/post-js-header.js 47b6b281f39ad59fa6e8b658308cd98ea292c286a68407b35ff3ed9cfd281a62
F ext/wasm/api/pre-js.c-pp.js b88499dc303c21fc3f55f2c364a0f814f587b60a95784303881169f9e91c1d5f
F ext/wasm/api/sqlite3-api-cleanup.js 680d5ccfff54459db136a49b2199d9f879c8405d9c99af1dda0cc5e7c29056f4
-F ext/wasm/api/sqlite3-api-glue.js 232bdd95abf27ce6e92b5d7e7ad28118992365520599fcc1b91cf25a430ea8bf
+F ext/wasm/api/sqlite3-api-glue.js e16bf1de4c08d3906298d532e1e61478791286e768d7ba1538ca90d0fa344e12
F ext/wasm/api/sqlite3-api-oo1.js 045c98796950c22556fc0842fe9f0d9a67f31920f247e24fb440571cdb6be5b0
-F ext/wasm/api/sqlite3-api-prologue.js f8d21f26615c332de98e0eb85f2e55f7b90e3d522c0357e07d6e1de8c5681e49
+F ext/wasm/api/sqlite3-api-prologue.js e862e5b79d565bd79c8ff59ebb6618a07ecb1a0262a1560dc6a10aa0f4d6f531
F ext/wasm/api/sqlite3-api-worker1.js c9ef8865f072e61251260b218aa4ed614a21a25e9e3cc6f22acf81794d32fc0b
F ext/wasm/api/sqlite3-license-version-header.js a661182fc93fc2cf212dfd0b987f8e138a3ac98f850b1112e29b5fbdaecc87c3
F ext/wasm/api/sqlite3-opfs-async-proxy.js 7795b84b66a7a8dedc791340709b310bb497c3c72a80bef364fa2a58e2ddae3f
F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc
F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e
F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0
-P 18a5480f1e0dca55703b43fa17685a4cc577cab8841ce47c807af02348ad85ee
-R 160fe994465231b79e87837be38dc79b
+P eff5d3bec29043cc1182bbb5229040dac5ff50264d025e354736bb63b4bc97a0
+R 6ff80c69205054a7da640050cde0ccdf
U stephan
-Z 59b56e199ffa18f089018d23ec3db748
+Z 3c914ac569efd4e323dbc54f2636bac4
# Remove this line to create a well-formed Fossil manifest.
-eff5d3bec29043cc1182bbb5229040dac5ff50264d025e354736bb63b4bc97a0
\ No newline at end of file
+ae3ae92ec45d3d5de92e70876502f8108fc3fcd87848e86c2b83f8842f1ff139
\ No newline at end of file