it's that I'm under the impression that once you use $1 once, perl needs to track it for every regex in the entire program...
You're thinking of $&, $` and $'. They are always set by all regexps when they are used anywhere in the program.
$1 .. $9 are always set by every regexps that succeeds. When a given regexp has no corresponding capture, they are set to undefined. No attention is payed to whether $1 .. $9 are used anywhere.
In reply to Re^3: Using a regex to catch interpreters
by ikegami
in thread Using a regex to catch interpreters
by eastcoastcoder
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |