in reply to Re: __DATA__ Inconsistency
in thread __DATA__ Inconsistency

It does fail and it would add in the $_ some messages that occurred early on, but again it is so inconsistent. I wish I could re-produce it.

What I did was I "initialized" $_ to be safe.
$test = qq(); $_ = qq(); $test = $test . $_ while(<DATA>);

Replies are listed 'Best First'.
Re^3: __DATA__ Inconsistency
by GrandFather (Saint) on Oct 02, 2008 at 23:51 UTC

    In your sample code there is no "early on". Show us the actual code that is failing rather than what you consider to be a representative snippet. The code you have shown can not fail in the way you describe!


    Perl reduces RSI - it saves typing