Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^4: Perl 5.34 is released

by LanX (Saint)
on May 23, 2021 at 12:41 UTC ( [id://11132922]=note: print w/replies, xml ) Need Help??


in reply to Re^3: Perl 5.34 is released
in thread Perl 5.34 is released

> $str =~ /[o]{,2}/'

missing the point!

Already proven in the post you downvoted (line 13)

Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery

Replies are listed 'Best First'.
Re^5: Perl 5.34 is released
by 1nickt (Canon) on May 23, 2021 at 12:53 UTC

    "the post you downvoted"

    Nope again. (Update for the slow-to-comprehend: I did not downvote the post you linked to.)


    The way forward always starts with a minimal test.
      > again

      Orly?

      So please explain!

      $ perl -Mstrict -wE 'my $str = "foobar"; say 1 if $str =~ /{,3}/; say +$]' 5.028002 $

      (Update perl version added)

      update

      >perl -Mstrict -wE "my $str = 'foobar'; say 1 if $str =~ /{,3}/; say $ +],':',$^O" 5.032001:MSWin32

      Cheers Rolf
      (addicted to the Perl Programming Language :)
      Wikisyntax for the Monastery

        I would guess there's a special case when the brace is the first character in the regex.

        $ perl -wE 'say $]; say "Match literal" if "{,3}" =~ m<{,3}> && "x" !~ + m<{,3}>;' 5.030001 Match literal $ perl -wE 'say $]; say "Match space" if " {,3}" =~ m< {,3}> && "x" !~ + m< {,3}>;' Unescaped left brace in regex is illegal here in regex; marked by <-- +HERE in m/ { <-- HERE ,3}/ at -e line 1.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11132922]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others contemplating the Monastery: (6)
As of 2024-04-23 18:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found