in reply to Why can't $` $& $' be enabled on a per-regex basis?
They're globals, so local has an influence:
prints:perl -e'$_="fafbfc";/fc/;{local $`;/bf/;print $`,$/} print $`, $/'
faf fafb
After Compline,
Zaxo
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Why can't $` $& $' be enabled on a per-regex basis?
by Courage (Parson) on Aug 10, 2002 at 06:45 UTC |