Re: unless(...) terser than if(!...)
by Vincent Pit other posts by this author
Aug 29 2008 1:47PM messages near this date
Re: unless(...) terser than if(!...)
|
Re: unless(...) terser than if(!...)
As requested by Rafael, I added some overloading and deparse tests. I
also added a few basic tests.
While testing, I realized that the "if (!$x)" wasn't optimized if it was
the last statement of a sequence. But it's actually the good thing,
because "do { 1 unless $x }" and "do { 1 if not $x }" actually don't
return the same thing when $x is true.
Thread:
Nicholas Clark
Vincent Pit
Vincent Pit
Rafael Garcia-Suarez
Yitzchak Scott-Thoennes
Graham Barr
Nicholas Clark
David Nicol
Vincent Pit
David Nicol
|