p4raw-id: //depot/cfgperl@3649
# regcomp.c
use warning 'unsafe' ;
$_ = "" ;
-/[:foo:]/;
+/[:alpha:]/;
/[.bar.]/;
/[=zog=]/;
+/[[:alpha:]]/;
+/[[.foo.]]/;
+/[[=bar=]]/;
+/[:zog:]/;
no warning 'unsafe' ;
-/[a[:foo:]b]/;
-/[a[.bar.]b]/;
-/[a[=zog=]b]/;
+/[:alpha:]/;
+/[.foo.]/;
+/[=bar=]/;
+/[[:alpha:]]/;
+/[[.foo.]]/;
+/[[=bar=]]/;
+/[:zog:]/;
+/[[:zog:]]/;
EXPECT
Character class syntax [: :] belongs inside character classes at - line 4.
Character class syntax [. .] belongs inside character classes at - line 5.
Character class syntax [. .] is reserved for future extensions at - line 5.
Character class syntax [= =] belongs inside character classes at - line 6.
Character class syntax [= =] is reserved for future extensions at - line 6.
+Character class syntax [. .] is reserved for future extensions at - line 8.
+Character class syntax [= =] is reserved for future extensions at - line 9.
+Character class syntax [: :] belongs inside character classes at - line 10.
+Character class [:zog:] unknown at - line 19.