summaryrefslogtreecommitdiff
path: root/regcomp.c
diff options
context:
space:
mode:
authorJeffrey Friedl <jfriedl@regex.info>2000-07-16 10:55:29 -0700
committerJarkko Hietaniemi <jhi@iki.fi>2000-07-26 04:31:01 +0000
commit3802429d267c8d589218258636c61462cb33dd22 (patch)
tree9470fbcdfc94c0a188ef166ba1382489a8d7e242 /regcomp.c
parentf3b76584ef7773843ba39a11b8bd91238af59f12 (diff)
downloadperl-3802429d267c8d589218258636c61462cb33dd22.tar.gz
Make the unimplemented POSIX regex features [[.cc.]] and [[=c=]]
to be fatal errors (instead of by default ignoring them, and ignoring with a bug: even though -w gave an error, the opening [ was left in) Reported in: Subject: [ID 20000716.024] [=cc=] / [:blank:] Message-Id: <200007170055.RAA23528@fummy.dsl.yahoo.com> p4raw-id: //depot/perl@6439
Diffstat (limited to 'regcomp.c')
-rw-r--r--regcomp.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/regcomp.c b/regcomp.c
index bbdfdc327d..a15eb233de 100644
--- a/regcomp.c
+++ b/regcomp.c
@@ -2842,10 +2842,10 @@ S_regpposixcc(pTHX_ I32 value)
Perl_croak(aTHX_
"Character class [:%.*s:] unknown",
t - s - 1, s + 1);
- } else if (ckWARN(WARN_REGEXP) && !SIZE_ONLY)
+ } else if (!SIZE_ONLY)
/* [[=foo=]] and [[.foo.]] are still future. */
- Perl_warner(aTHX_ WARN_REGEXP,
- "Character class syntax [%c %c] is reserved for future extensions", c, c);
+ Perl_croak(aTHX_
+ "Character class syntax [%c %c] is reserved for future extensions", c, c);
} else {
/* Maternal grandfather:
* "[:" ending in ":" but not in ":]" */
@@ -2873,8 +2873,8 @@ S_checkposixcc(pTHX)
Perl_warner(aTHX_ WARN_REGEXP,
"Character class syntax [%c %c] belongs inside character classes", c, c);
if (c == '=' || c == '.')
- Perl_warner(aTHX_ WARN_REGEXP,
- "Character class syntax [%c %c] is reserved for future extensions", c, c);
+ Perl_croak(aTHX_
+ "Character class syntax [%c %c] is reserved for future extensions", c, c);
}
}
}