X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/3ca4086b22723db16d7e0fc23aa9021b4785096a..2e14066008229145e2da7b9f05a478ce38631f83:/src/regex/regcomp.c diff --git a/src/regex/regcomp.c b/src/regex/regcomp.c index 2a7fd6e0b9..83edc37b34 100644 --- a/src/regex/regcomp.c +++ b/src/regex/regcomp.c @@ -235,11 +235,11 @@ struct vars { #define ISERR() VISERR(v) #define VERR(vv,e) ((vv)->nexttype = EOS, ((vv)->err) ? (vv)->err :\ ((vv)->err = (e))) -#define ERR(e) VERR(v, e) /* record an error */ +#define ERR(e) (void)VERR(v, e) /* record an error */ #define NOERR() {if (ISERR()) return;} /* if error seen, return */ #define NOERRN() {if (ISERR()) return NULL;} /* NOERR with retval */ #define NOERRZ() {if (ISERR()) return 0;} /* NOERR with retval */ -#define INSIST(c, e) ((c) ? 0 : ERR(e)) /* if condition false, error */ +#define INSIST(c, e) (void)((c) ? (void)0 : ERR(e)) /* if condition false, error */ #define NOTE(b) (v->re->re_info |= (b)) /* note visible condition */ #define EMPTYARC(x, y) newarc(v->nfa, EMPTY, 0, x, y) @@ -899,7 +899,7 @@ struct subre *top; /* subtree top */ case BACKREF: /* the Feature From The Black Lagoon */ INSIST(type != LACON, REG_ESUBREG); INSIST(v->nextvalue < v->nsubs, REG_ESUBREG); - INSIST(v->subs[v->nextvalue] != NULL, REG_ESUBREG); + INSIST(v->subs[(int)v->nextvalue] != NULL, REG_ESUBREG); NOERR(); assert(v->nextvalue > 0); atom = subre(v, 'b', BACKR, lp, rp); @@ -2168,7 +2168,7 @@ size_t bufsize; if (t->retry != 0) sprintf(buf, "%d", t->retry); else - sprintf(buf, "0x%x", (int)t); /* may lose bits, that's okay */ + sprintf(buf, "0x%x", (int)(wxUIntPtr)(t)); /* may lose bits, that's okay */ return buf; }