/me assumes that $/=undef is being applied, to allow all the file to be sucked into the variable $var.
Er... no. The original poster mentioned line at a time processing. Assume the following code around my previous snippet:
while (defined($var = <FILE>)) { # code here }
/me also assumes that $var is subsequently being reused to store the matching criteria?
Wasn't very clear exactly what the original poster wanted to do with the results, so I left it deliberately vague :)
--
"Perl makes the fun jobs fun
and the boring jobs bearable" - me
In reply to Re: Re: Re: how to match and assign?
by davorg
in thread how to match and assign?
by slok
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |