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

Unified Diff: third_party/sqlite/src/ext/misc/regexp.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/misc/percentile.c ('k') | third_party/sqlite/src/ext/misc/remember.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/sqlite/src/ext/misc/regexp.c
diff --git a/third_party/sqlite/src/ext/misc/regexp.c b/third_party/sqlite/src/ext/misc/regexp.c
index 7244d5299815b3607fb8098172eabcfc1a5fe7a6..b4a8ab5c0423543adc4068baca271597fd70a422 100644
--- a/third_party/sqlite/src/ext/misc/regexp.c
+++ b/third_party/sqlite/src/ext/misc/regexp.c
@@ -136,7 +136,7 @@ struct ReCompiled {
static void re_add_state(ReStateSet *pSet, int newState){
unsigned i;
for(i=0; i<pSet->nState; i++) if( pSet->aState[i]==newState ) return;
- pSet->aState[pSet->nState++] = newState;
+ pSet->aState[pSet->nState++] = (ReStateNumber)newState;
}
/* Extract the next unicode character from *pzIn and return it. Advance
@@ -358,7 +358,7 @@ static int re_insert(ReCompiled *p, int iBefore, int op, int arg){
p->aArg[i] = p->aArg[i-1];
}
p->nState++;
- p->aOp[iBefore] = op;
+ p->aOp[iBefore] = (char)op;
p->aArg[iBefore] = arg;
return iBefore;
}
@@ -677,12 +677,12 @@ const char *re_compile(ReCompiled **ppRe, const char *zIn, int noCase){
for(j=0, i=1; j<sizeof(pRe->zInit)-2 && pRe->aOp[i]==RE_OP_MATCH; i++){
unsigned x = pRe->aArg[i];
if( x<=127 ){
- pRe->zInit[j++] = x;
+ pRe->zInit[j++] = (unsigned char)x;
}else if( x<=0xfff ){
- pRe->zInit[j++] = 0xc0 | (x>>6);
+ pRe->zInit[j++] = (unsigned char)(0xc0 | (x>>6));
pRe->zInit[j++] = 0x80 | (x&0x3f);
}else if( x<=0xffff ){
- pRe->zInit[j++] = 0xd0 | (x>>12);
+ pRe->zInit[j++] = (unsigned char)(0xd0 | (x>>12));
pRe->zInit[j++] = 0x80 | ((x>>6)&0x3f);
pRe->zInit[j++] = 0x80 | (x&0x3f);
}else{
« no previous file with comments | « third_party/sqlite/src/ext/misc/percentile.c ('k') | third_party/sqlite/src/ext/misc/remember.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698