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

Re: [perl #134172] commit 027471cf breaks t/op/sprintf2.t onFreeBSD-11

Thread Previous | Thread Next
From:
Karl Williamson
Date:
July 30, 2019 04:13
Subject:
Re: [perl #134172] commit 027471cf breaks t/op/sprintf2.t onFreeBSD-11
Message ID:
93473231-740b-ebf3-fa93-9619414ee0d3@khwilliamson.com
On 7/25/19 8:17 AM, Hugo van der Sanden via RT wrote:
> On Wed, 24 Jul 2019 17:38:13 -0700, tonyc wrote:
>> It looks reasonable to me.
> 
> Thanks.
> 
>> One thing I noticed in the original code was that
>> STORE_LC_NUMERIC_SET_TO_NEEDED() could call the possibly expensive
>> IN_LC(LC_NUMERIC) up to three times:
>>
>> +                    (   (  in_lc_numeric &&
>> _NOT_IN_NUMERIC_UNDERLYING)     \
>> +                     || (! in_lc_numeric &&
>> _NOT_IN_NUMERIC_STANDARD)));    \
>> +            if (in_lc_numeric) {
>> \
>>
>> (for a bare STORE_LC_NUMERIC_SET_TO_NEEDED() in_lc_numeric is
>> IN_LC(LC_NUMERIC) )
> 
> Yes, I addressed the same in my second patch, in a slightly different manner.
> 
> Hugo
> 
> ---
> via perlbug:  queue: perl5 status: open
> https://rt.perl.org/Ticket/Display.html?id=134172
> 

The patches both look good to me.

I have two very minor concerns.

Is saying foo({...}) portable?

And on platforms that don't have locales enabled, is it ok to just say 
"block;", or should this be wrapped in a STMT_START STMT_END

As far as the names, I don't know.  It's not clear to me what the _i 
suffix is supposed to mean, so if you go with that name, it should be 
documented.  If it is meant to mean 'internal', often using an 
underscore prefix is the convention.  But it's not really private,, so I 
don't know.

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