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

Re^2: strange usage of s///

by smls (Friar)
on Sep 03, 2013 at 22:25 UTC ( #1052186=note: print w/ replies, xml ) Need Help??


in reply to Re: strange usage of s///
in thread strange usage of s/// [solved: Perl 5.14 and 5.16 bug]

Perl v5.18.1 handles them as one would expect:

perl -MO=Deparse -e '$_="abcdef"; s/@{[s".."."gr]}\K$"//; print' $_ = 'abcdef'; s[@{[s/.././gr];}\K$"][]; print $_; -e syntax OK
perl -MO=Deparse -e '$_="abcdef"; s/@{[s".."."gr]}\K //; print' $_ = 'abcdef'; s[@{[s/.././gr];}\K ][]; print $_; -e syntax OK

PS: With Perl v5.14.2 I get the same result as you.

(Testing environment was 64bit Linux in both cases.)

So yeah, strange indeed...


Comment on Re^2: strange usage of s///
Select or Download Code
Re^3: strange usage of s///
by brx (Pilgrim) on Sep 04, 2013 at 17:33 UTC

    Thank you very much, smls. Original post updated.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (10)
As of 2014-11-24 12:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My preferred Perl binaries come from:














    Results (141 votes), past polls