]> granicus.if.org Git - php/commitdiff
MFH: fix yet another annoying compile warning
authorAntony Dovgal <tony2001@php.net>
Fri, 13 Aug 2004 15:02:05 +0000 (15:02 +0000)
committerAntony Dovgal <tony2001@php.net>
Fri, 13 Aug 2004 15:02:05 +0000 (15:02 +0000)
ext/ereg/regex/engine.c
ext/ereg/regex/regexec.c
regex/engine.c
regex/regexec.c

index c4bdc8079f075e84f206b56bf11c4d764f7a3a16..0682267f61801150f77d4fcb3d7486d4589e173f 100644 (file)
@@ -270,7 +270,7 @@ sopno stopst;
                /* figure out what it matched */
                switch (OP(m->g->strip[ss])) {
                case OEND:
-                       assert(nope);
+                       assert(PHP_REGEX_NOPE);
                        break;
                case OCHAR:
                        sp++;
@@ -286,7 +286,7 @@ sopno stopst;
                        break;
                case OBACK_:
                case O_BACK:
-                       assert(nope);
+                       assert(PHP_REGEX_NOPE);
                        break;
                /* cases where length of match is hard to find */
                case OQUEST_:
@@ -389,7 +389,7 @@ sopno stopst;
                case OOR1:
                case OOR2:
                case O_CH:
-                       assert(nope);
+                       assert(PHP_REGEX_NOPE);
                        break;
                case OLPAREN:
                        i = OPND(m->g->strip[ss]);
@@ -402,7 +402,7 @@ sopno stopst;
                        m->pmatch[i].rm_eo = sp - m->offp;
                        break;
                default:                /* uh oh */
-                       assert(nope);
+                       assert(PHP_REGEX_NOPE);
                        break;
                }
        }
@@ -606,12 +606,12 @@ sopno lev;                        /* PLUS nesting level */
                return(NULL);
                break;
        default:                /* uh oh */
-               assert(nope);
+               assert(PHP_REGEX_NOPE);
                break;
        }
 
        /* "can't happen" */
-       assert(nope);
+       assert(PHP_REGEX_NOPE);
        /* NOTREACHED */
        return((unsigned char *)NULL);  /* dummy */
 }
@@ -914,7 +914,7 @@ register states aft;                /* states already known reachable after */
                        FWD(aft, aft, 1);
                        break;
                default:                /* ooooops... */
-                       assert(nope);
+                       assert(PHP_REGEX_NOPE);
                        break;
                }
        }
index c8cb8fdf5644ad3b885a46f364678c454d4572a3..bbfe094c96ca2e54e9331b14c194b4d31a5d6ff1 100644 (file)
@@ -16,7 +16,7 @@
 #include "utils.h"
 #include "regex2.h"
 
-static int nope = 0;           /* for use in asserts; shuts lint up */
+#define PHP_REGEX_NOPE 0;              /* for use in asserts; shuts lint up */
 
 /* macros for manipulating states, small version */
 #define        states  unsigned
index c4bdc8079f075e84f206b56bf11c4d764f7a3a16..0682267f61801150f77d4fcb3d7486d4589e173f 100644 (file)
@@ -270,7 +270,7 @@ sopno stopst;
                /* figure out what it matched */
                switch (OP(m->g->strip[ss])) {
                case OEND:
-                       assert(nope);
+                       assert(PHP_REGEX_NOPE);
                        break;
                case OCHAR:
                        sp++;
@@ -286,7 +286,7 @@ sopno stopst;
                        break;
                case OBACK_:
                case O_BACK:
-                       assert(nope);
+                       assert(PHP_REGEX_NOPE);
                        break;
                /* cases where length of match is hard to find */
                case OQUEST_:
@@ -389,7 +389,7 @@ sopno stopst;
                case OOR1:
                case OOR2:
                case O_CH:
-                       assert(nope);
+                       assert(PHP_REGEX_NOPE);
                        break;
                case OLPAREN:
                        i = OPND(m->g->strip[ss]);
@@ -402,7 +402,7 @@ sopno stopst;
                        m->pmatch[i].rm_eo = sp - m->offp;
                        break;
                default:                /* uh oh */
-                       assert(nope);
+                       assert(PHP_REGEX_NOPE);
                        break;
                }
        }
@@ -606,12 +606,12 @@ sopno lev;                        /* PLUS nesting level */
                return(NULL);
                break;
        default:                /* uh oh */
-               assert(nope);
+               assert(PHP_REGEX_NOPE);
                break;
        }
 
        /* "can't happen" */
-       assert(nope);
+       assert(PHP_REGEX_NOPE);
        /* NOTREACHED */
        return((unsigned char *)NULL);  /* dummy */
 }
@@ -914,7 +914,7 @@ register states aft;                /* states already known reachable after */
                        FWD(aft, aft, 1);
                        break;
                default:                /* ooooops... */
-                       assert(nope);
+                       assert(PHP_REGEX_NOPE);
                        break;
                }
        }
index c8cb8fdf5644ad3b885a46f364678c454d4572a3..bbfe094c96ca2e54e9331b14c194b4d31a5d6ff1 100644 (file)
@@ -16,7 +16,7 @@
 #include "utils.h"
 #include "regex2.h"
 
-static int nope = 0;           /* for use in asserts; shuts lint up */
+#define PHP_REGEX_NOPE 0;              /* for use in asserts; shuts lint up */
 
 /* macros for manipulating states, small version */
 #define        states  unsigned