mirror of
https://github.com/sqlite/sqlite.git
synced 2025-07-27 20:41:58 +03:00
Internal JS cleanups. Correct part of [ac136925a645] to account for the eTextRep flag being able to hold flags other than the encoding.
FossilOrigin-Name: 1dfc03ab1e0269807beef27bf884ab9ead7553d4a5f6ed213f812d7fa052045f
This commit is contained in:
@ -425,7 +425,9 @@ self.sqlite3ApiBootstrap = function sqlite3ApiBootstrap(
|
||||
any encoding other than sqlite3.SQLITE_UTF8. The JS API does not
|
||||
currently support any other encoding and likely never
|
||||
will. This function does not replace that argument on its own
|
||||
because it may contain other flags.
|
||||
because it may contain other flags. As a special case, if
|
||||
the bottom 4 bits of that argument are 0, SQLITE_UTF8 is
|
||||
assumed.
|
||||
|
||||
2) Any of the four final arguments may be either WASM pointers
|
||||
(assumed to be function pointers) or JS Functions. In the
|
||||
@ -433,6 +435,10 @@ self.sqlite3ApiBootstrap = function sqlite3ApiBootstrap(
|
||||
sqlite3.capi.wasm.installFunction() and that wrapper is passed
|
||||
on to the native implementation.
|
||||
|
||||
For consistency with the C API, it requires the same number of
|
||||
arguments. It returns capi.SQLITE_MISUSE if passed any other
|
||||
argument count.
|
||||
|
||||
The semantics of JS functions are:
|
||||
|
||||
xFunc: is passed `(pCtx, ...values)`. Its return value becomes
|
||||
|
Reference in New Issue
Block a user