Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(797)

Unified Diff: third_party/sqlite/src/ext/fts5/fts5_tokenize.c

Issue 2751253002: [sql] Import SQLite 3.17.0. (Closed)
Patch Set: also clang on Linux i386 Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/sqlite/src/ext/fts5/fts5_test_tok.c ('k') | third_party/sqlite/src/ext/fts5/fts5_unicode2.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/sqlite/src/ext/fts5/fts5_tokenize.c
diff --git a/third_party/sqlite/src/ext/fts5/fts5_tokenize.c b/third_party/sqlite/src/ext/fts5/fts5_tokenize.c
index e60183c0957b5c2042b6f43e073259452e0c2cec..b72a0c24ab9f4c227c9197443f137d2cf67130cd 100644
--- a/third_party/sqlite/src/ext/fts5/fts5_tokenize.c
+++ b/third_party/sqlite/src/ext/fts5/fts5_tokenize.c
@@ -62,12 +62,13 @@ static void fts5AsciiDelete(Fts5Tokenizer *p){
** Create an "ascii" tokenizer.
*/
static int fts5AsciiCreate(
- void *pCtx,
+ void *pUnused,
const char **azArg, int nArg,
Fts5Tokenizer **ppOut
){
int rc = SQLITE_OK;
AsciiTokenizer *p = 0;
+ UNUSED_PARAM(pUnused);
if( nArg%2 ){
rc = SQLITE_ERROR;
}else{
@@ -116,7 +117,7 @@ static void asciiFold(char *aOut, const char *aIn, int nByte){
static int fts5AsciiTokenize(
Fts5Tokenizer *pTokenizer,
void *pCtx,
- int flags,
+ int iUnused,
const char *pText, int nText,
int (*xToken)(void*, int, const char*, int nToken, int iStart, int iEnd)
){
@@ -130,6 +131,8 @@ static int fts5AsciiTokenize(
char *pFold = aFold;
unsigned char *a = p->aTokenChar;
+ UNUSED_PARAM(iUnused);
+
while( is<nText && rc==SQLITE_OK ){
int nByte;
@@ -323,13 +326,15 @@ static void fts5UnicodeDelete(Fts5Tokenizer *pTok){
** Create a "unicode61" tokenizer.
*/
static int fts5UnicodeCreate(
- void *pCtx,
+ void *pUnused,
const char **azArg, int nArg,
Fts5Tokenizer **ppOut
){
int rc = SQLITE_OK; /* Return code */
Unicode61Tokenizer *p = 0; /* New tokenizer object */
+ UNUSED_PARAM(pUnused);
+
if( nArg%2 ){
rc = SQLITE_ERROR;
}else{
@@ -386,7 +391,7 @@ static int fts5UnicodeIsAlnum(Unicode61Tokenizer *p, int iCode){
static int fts5UnicodeTokenize(
Fts5Tokenizer *pTokenizer,
void *pCtx,
- int flags,
+ int iUnused,
const char *pText, int nText,
int (*xToken)(void*, int, const char*, int nToken, int iStart, int iEnd)
){
@@ -402,6 +407,8 @@ static int fts5UnicodeTokenize(
int nFold = p->nFold;
const char *pEnd = &aFold[nFold-6];
+ UNUSED_PARAM(iUnused);
+
/* Each iteration of this loop gobbles up a contiguous run of separators,
** then the next token. */
while( rc==SQLITE_OK ){
@@ -1220,7 +1227,7 @@ int sqlite3Fts5TokenizerInit(fts5_api *pApi){
int rc = SQLITE_OK; /* Return code */
int i; /* To iterate through builtin functions */
- for(i=0; rc==SQLITE_OK && i<(int)ArraySize(aBuiltin); i++){
+ for(i=0; rc==SQLITE_OK && i<ArraySize(aBuiltin); i++){
rc = pApi->xCreateTokenizer(pApi,
aBuiltin[i].zName,
(void*)pApi,
« no previous file with comments | « third_party/sqlite/src/ext/fts5/fts5_test_tok.c ('k') | third_party/sqlite/src/ext/fts5/fts5_unicode2.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698