in reply to Re: how to match and assign?
in thread how to match and assign?

/me assumes that $/=undef is being applied, to allow all the file to be sucked into the variable $var.
/me also assumes that $var is subsequently being reused to store the matching criteria?

Or am I being dumb?

--
Brother Frankus.

Replies are listed 'Best First'.
Re: Re: Re: how to match and assign?
by davorg (Chancellor) on Apr 24, 2001 at 15:11 UTC
    /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 :)

    --
    <http://www.dave.org.uk>

    "Perl makes the fun jobs fun
    and the boring jobs bearable" - me