in reply to Re: Using 'e' in s///
in thread Using 'e' in s///

You cannot modify the match variables, anyway.

That's not an attempt to modify $1 at all. It's an attempt to use it as a pattern, which is fine.

$ perl -le '$_="foo"; /(o)/; s/$1/x/; print' fxo
You seem to have confused that with $1 =~ s/.../.../;

-sauoq
"My two cents aren't worth a dime.";