in reply to
String substitution
Because
s///
treats the first string is a regex, and not all regexes match their own textual representation. Hint:
[...]
has a special meaning, see
perlretut
.
You can avoid that with
\Q$EXPR\E
.
Perl 6
- links to (nearly) everything that is Perl 6.
Comment on
Re: String substitution
Select
or
Download
Code
In Section
Seekers of Perl Wisdom