Merge branch 'master' into pure-ops
[p5sagit/Function-Parameters.git] / Parameters.xs
index c9429f0..904ea25 100644 (file)
@@ -26,7 +26,7 @@ See http://dev.perl.org/licenses/ for more information.
        WARNINGS_ENABLEW(-Wall) \
        WARNINGS_ENABLEW(-Wextra) \
        WARNINGS_ENABLEW(-Wundef) \
-       WARNINGS_ENABLEW(-Wshadow) \
+       /* WARNINGS_ENABLEW(-Wshadow) :-( */ \
        WARNINGS_ENABLEW(-Wbad-function-cast) \
        WARNINGS_ENABLEW(-Wcast-align) \
        WARNINGS_ENABLEW(-Wwrite-strings) \
@@ -150,15 +150,12 @@ static void free_ptr_op(pTHX_ void *vp) {
        Safefree(pp);
 }
 
-#define sv_eq_pvs(SV, S) sv_eq_pvn(aTHX_ SV, "" S "", sizeof (S) - 1)
+#define sv_eq_pvs(SV, S) my_sv_eq_pvn(aTHX_ SV, "" S "", sizeof (S) - 1)
 
-static int sv_eq_pvn(pTHX_ SV *sv, const char *p, STRLEN n) {
+static int my_sv_eq_pvn(pTHX_ SV *sv, const char *p, STRLEN n) {
        STRLEN sv_len;
        const char *sv_p = SvPV(sv, sv_len);
-       return
-               sv_len == n &&
-               memcmp(sv_p, p, n) == 0
-       ;
+       return memcmp(sv_p, p, n) == 0;
 }
 
 
@@ -206,7 +203,6 @@ static int parse_fun(pTHX_ OP **pop, const char *keyword_ptr, STRLEN keyword_len
        SV *proto;
        OP **attrs_sentinel, *body;
        unsigned builtin_attrs;
-       int saw_colon;
        STRLEN len;
        char *s;
        I32 c;
@@ -310,7 +306,6 @@ static int parse_fun(pTHX_ OP **pop, const char *keyword_ptr, STRLEN keyword_len
 
        /* prototype */
        proto = NULL;
-       saw_colon = 0;
        c = lex_peek_unichar(0);
        if (c == ':') {
                lex_read_unichar(0);