Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change

Re^2: strange usage of s///

by brx (Pilgrim)
on Sep 03, 2013 at 20:27 UTC ( #1052174=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]

$_="abcdef"; s/@{[s".."."gr]}/$& /; print; [download]
This variation of yours does in fact work (prints "abc def"), and so do the following ones (which are closer to the original solution by "tails")

Not for me. It prints "...abcdef" (with perl v5.14.4).

Thus I conclude that the original "solution" is the result of a typo (separator '/' put in the wrong place), and cannot work.

No typo. Code is good. You can test it on:

English is not my mother tongue.
Les tongues de ma mère sont "made in France".

Comment on Re^2: strange usage of s///
Download Code

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (7)
As of 2015-10-13 23:13 GMT
Find Nodes?
    Voting Booth?

    Does Humor Belong in Programming?

    Results (316 votes), past polls