Your skill will accomplish what the force of many cannot |
|
PerlMonks |
Re2: Perl Bug in Regex Code Block?by Hofmator (Curate) |
on Sep 03, 2001 at 16:59 UTC ( [id://109859]=note: print w/replies, xml ) | Need Help?? |
When you use my, you are creating a variable which will disappear when it goes out of scope.I'm well aware of that ... but the regex is taking place inside this scope and so the lexical variables should be accessible inside the regex. This works the first time as expected but it doesn't work on the second and third iteration of the loop. Maybe you have misunderstood my question, I'm not confused that the last line of my code doesn't print anything. It was only included for the (working) run with our instead of my. I want to know, why it's changing its behaviour inside the loop. I hope this clarifies my problem ... -- Hofmator
In Section
Seekers of Perl Wisdom
|
|