develooper Front page | perl.perl5.porters | Postings from July 2009

Re: maint-5.10 snapshot (aka "RC0")

Thread Previous | Thread Next
From:
Vincent Pit
Date:
July 8, 2009 02:07
Subject:
Re: maint-5.10 snapshot (aka "RC0")
Message ID:
4A5461B5.8010707@profvince.com

>> Maybe this optimisation :
>>
>> [rafael@scipion ~]$ perl5.10.0 -MO=Deparse -e 'if(not $a or not $b){}'
>> if (not $a or not $b) {
>>     ();
>> }
>> -e syntax OK
>> [rafael@scipion ~]$ bleadperl -MO=Deparse -e 'if(not $a or not $b){}'
>> unless ($a and $b) {
>>     ();
>> }
>> -e syntax OK
>>
>> Which seems to come from :
>>
>> commit edbe35ea95baf286c38bf4d7db7d18b82ecce254
>> Author: Vincent Pit <perl@profvince.com>
>> Date:   Sat Aug 30 00:47:28 2008 +0200
>>
>>     Re: unless(...) terser than if(!...)
>>     Message-ID: <48B86060.4090905@profvince.com>
>>
>>     p4raw-id: //depot/perl@34310
>>
>> Not sure Deparse will be able to cope with this.
>>     
>
> This is highly possible.
Or not, since edbe35ea95baf286c38bf4d7db7d18b82ecce254 wasn't cherry-picked in maint.

The problem seems to happen only in elseif, hence I think this is related with the constant folding in elseif issue. Maybe Devel::Cover has to be taught about the new inserted lineseq OP.


Vincent.

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About