Skip to content

Commit f78f6d1

Browse files
committed
perlre: Update obsolete example
/foo{4,3}/ now emits a message, contrary to what the pod claims. Use a different example that doesn't emit a message
1 parent f001cc4 commit f78f6d1

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

pod/perlre.pod

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -543,11 +543,10 @@ character. In particular, the lower quantifier bound is not optional,
543543
and a typo in a quantifier silently causes it to be treated as the
544544
literal characters. For example,
545545

546-
/o{4,3}/
546+
/o{4,a}/
547547

548-
looks like a quantifier that matches 0 times, since 4 is greater than 3,
549-
but it really means to match the sequence of six characters
550-
S<C<"o { 4 , 3 }">>. It is planned to eventually require literal uses
548+
compiles to match the sequence of six characters
549+
S<C<"o { 4 , a }">>. It is planned to eventually require literal uses
551550
of curly brackets to be escaped, say by preceding them with a backslash
552551
or enclosing them within square brackets, (C<"\{"> or C<"[{]">). This
553552
change will allow for future syntax extensions (like making the lower

0 commit comments

Comments
 (0)