|
|
|
Clear questions and runnable code get the best and fastest answer |
|
| PerlMonks |
Re: Capturing parentheses out of scopeby Anonyrnous Monk (Hermit) |
| on Jan 20, 2011 at 21:04 UTC ( [id://883404]=note: print w/replies, xml ) | Need Help?? |
|
You could assign them (i.e. $1..$N) to an array declared in the outer scope — or in the if-scope: if (my @f = /... But what would you expect them to hold if the regex doesn't match? Or is it only the second test (and ( !/numsnp=[1-4]\s+/ )) that is expected to fail in these cases?
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||||||||||||||