/ Check-in [f301db3c]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Make the new sqlite3_vtab_collation() interface accessible to loadable extensions.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: f301db3c2343fd2086bc5b69a17b2d226175584ccd09549ebb2cb603590da487
User & Date: drh 2018-01-16 20:50:37
Context
2018-01-16
21:00
Fix compiler warning in the FTS5 test interface. check-in: 2ab4e8d5 user: drh tags: trunk
20:50
Make the new sqlite3_vtab_collation() interface accessible to loadable extensions. check-in: f301db3c user: drh tags: trunk
20:44
Fix a test problem causing an error in fts5fault9.test. check-in: 8e204811 user: dan tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/loadext.c.

   429    429     sqlite3_prepare_v3,
   430    430     sqlite3_prepare16_v3,
   431    431     sqlite3_bind_pointer,
   432    432     sqlite3_result_pointer,
   433    433     sqlite3_value_pointer,
   434    434     /* Version 3.22.0 and later */
   435    435     sqlite3_vtab_nochange,
   436         -  sqlite3_value_nochange
          436  +  sqlite3_value_nochange,
          437  +  sqlite3_vtab_collation
   437    438   };
   438    439   
   439    440   /*
   440    441   ** Attempt to load an SQLite extension library contained in the file
   441    442   ** zFile.  The entry point is zProc.  zProc may be 0 in which case a
   442    443   ** default entry point name (sqlite3_extension_init) is used.  Use
   443    444   ** of the default name is recommended.

Changes to src/sqlite3ext.h.

   290    290     int (*prepare16_v3)(sqlite3*,const void*,int,unsigned int,
   291    291                         sqlite3_stmt**,const void**);
   292    292     int (*bind_pointer)(sqlite3_stmt*,int,void*,const char*,void(*)(void*));
   293    293     void (*result_pointer)(sqlite3_context*,void*,const char*,void(*)(void*));
   294    294     void *(*value_pointer)(sqlite3_value*,const char*);
   295    295     int (*vtab_nochange)(sqlite3_context*);
   296    296     int (*value_nochange)(sqlite3_value*);
          297  +  const char *(*vtab_collation)(sqlite3_index_info*,int);
   297    298   };
   298    299   
   299    300   /*
   300    301   ** This is the function signature used for all extension entry points.  It
   301    302   ** is also defined in the file "loadext.c".
   302    303   */
   303    304   typedef int (*sqlite3_loadext_entry)(
................................................................................
   559    560   #define sqlite3_prepare16_v3           sqlite3_api->prepare16_v3
   560    561   #define sqlite3_bind_pointer           sqlite3_api->bind_pointer
   561    562   #define sqlite3_result_pointer         sqlite3_api->result_pointer
   562    563   #define sqlite3_value_pointer          sqlite3_api->value_pointer
   563    564   /* Version 3.22.0 and later */
   564    565   #define sqlite3_vtab_nochange          sqlite3_api->vtab_nochange
   565    566   #define sqlite3_value_nochange         sqltie3_api->value_nochange
          567  +#define sqlite3_vtab_collation         sqltie3_api->vtab_collation
   566    568   #endif /* !defined(SQLITE_CORE) && !defined(SQLITE_OMIT_LOAD_EXTENSION) */
   567    569   
   568    570   #if !defined(SQLITE_CORE) && !defined(SQLITE_OMIT_LOAD_EXTENSION)
   569    571     /* This case when the file really is being compiled as a loadable 
   570    572     ** extension */
   571    573   # define SQLITE_EXTENSION_INIT1     const sqlite3_api_routines *sqlite3_api=0;
   572    574   # define SQLITE_EXTENSION_INIT2(v)  sqlite3_api=v;