Revert "regcomp.c: White-space only"
authorKarl Williamson <khw@cpan.org>
Wed, 2 Mar 2016 05:41:59 +0000 (22:41 -0700)
committerKarl Williamson <khw@cpan.org>
Wed, 2 Mar 2016 05:46:57 +0000 (22:46 -0700)
This reverts commit 7511771ceb229ce97939f643c6de73c6b1a371be, so that
the next commit can be cleanly reverted

regcomp.c

index d66a4c7..b12e2de 100644 (file)
--- a/regcomp.c
+++ b/regcomp.c
@@ -13831,25 +13831,24 @@ S_handle_possible_posix(pTHX_ RExC_state_t *pRExC_state,
         }
 
         if (*temp_ptr == open_char) {
-            temp_ptr++;
-            if (*temp_ptr == ']') {
                 temp_ptr++;
-                if (! found_problem && ! check_only) {
-                    RExC_parse = (char *) temp_ptr;
-                    vFAIL3("POSIX syntax [%c %c] is reserved for future "
-                            "extensions", open_char, open_char);
-                }
+                if (*temp_ptr == ']') {
+                    temp_ptr++;
+                    if (! found_problem && ! check_only) {
+                        RExC_parse = (char *) temp_ptr;
+                        vFAIL3("POSIX syntax [%c %c] is reserved for future "
+                               "extensions", open_char, open_char);
+                    }
 
-                /* Here, the syntax wasn't completely valid, or else the call
-                 * is to check-only */
-                if (updated_parse_ptr) {
-                    *updated_parse_ptr = (char *) temp_ptr;
-                }
+                    /* Here, the syntax wasn't completely valid, or else the
+                     * call is to check-only */
+                    if (updated_parse_ptr) {
+                        *updated_parse_ptr = (char *) temp_ptr;
+                    }
 
-                return OOB_NAMEDCLASS;
-            }
+                    return OOB_NAMEDCLASS;
+                }
         }
-
         /* If we find something that started out to look like one of these
          * constructs, but isn't, we continue below so that it can be checked
          * for being a class name with a typo of '.' or '=' instead of a colon.