mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-15 11:41:13 +03:00
Additional documentation on sqlite3_bind_pointer() and sqlite3_result_pointer().
No changes to code. FossilOrigin-Name: b1572d4e05934a0dc1b73092acba652fa50e97552eb6e9a1cedea7c71055804b
This commit is contained in:
@@ -3890,7 +3890,12 @@ typedef struct sqlite3_context sqlite3_context;
|
||||
** host-language pointers into [application-defined SQL functions].
|
||||
** ^A parameter that is initialized using [sqlite3_bind_pointer()] appears
|
||||
** to be an ordinary SQL NULL value to everything other than
|
||||
** [sqlite3_value_pointer()]. The T parameter should be a static string.
|
||||
** [sqlite3_value_pointer()]. The T parameter should be a static string,
|
||||
** preferably a string literal. The procedure that invokes
|
||||
** sqlite3_bind_pointer(S,I,P,T) continues to own the P and T pointers and
|
||||
** must guarantee that those pointers remain valid until after the last
|
||||
** access via [sqlite3_value_pointer()]. The sqlite3_bind_pointer() routine
|
||||
** is part of the [pointer passing interface] added for SQLite 3.20.0.
|
||||
**
|
||||
** ^If any of the sqlite3_bind_*() routines are called with a NULL pointer
|
||||
** for the [prepared statement] or with a prepared statement for which
|
||||
@@ -5101,9 +5106,12 @@ typedef void (*sqlite3_destructor_type)(void*);
|
||||
** also associates the host-language pointer P or type T with that
|
||||
** NULL value such that the pointer can be retrieved within an
|
||||
** [application-defined SQL function] using [sqlite3_value_pointer()].
|
||||
** The T parameter should be a static string.
|
||||
** This mechanism can be used to pass non-SQL values between
|
||||
** application-defined functions.
|
||||
** The T parameter should be a static string and preferably a string
|
||||
** literal. The procedure that invokes sqlite3_result_pointer(C,P,T)
|
||||
** continues to own the P and T pointers and must guarantee that
|
||||
** those pointers remain valid until after the last access via
|
||||
** [sqlite3_value_pointer()]. The sqlite3_result_pointer() routine
|
||||
** is part of the [pointer passing interface] added for SQLite 3.20.0.
|
||||
**
|
||||
** If these routines are called from within the different thread
|
||||
** than the one containing the application-defined function that received
|
||||
|
||||
Reference in New Issue
Block a user