in reply to Re^2: Ulimit being reached
in thread Ulimit being reached
That's strange. They both work for me.# THIS WORKS print (OUT $line) || die "writing 'splat' $!"; # But putting || die on another line does not. i.e: # print (OUT $line) # || die "writing 'splat' $!";
Moreover, I see no reason why they would be different, in fact Deparse tells me they produce identical code:
Though you could dig further into the root cause of the difference you experienced, I suggest you just stick to the low precedence or and avoid parens with print as described earlier.% cat id1.pl print (OUT $line) || die "writing 'splat' $!"; % perl -MO=Deparse id1.pl die "writing 'splat' $!" unless print OUT $line; id1.pl syntax OK % cat id2.pl print (OUT $line) || die "writing 'splat' $!"; % perl -MO=Deparse id2.pl die "writing 'splat' $!" unless print OUT $line; id2.pl syntax OK
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Ulimit being reached
by Discipulus (Canon) on Jan 14, 2015 at 08:29 UTC |