[PATCH] Add C++ versions of iscanonical for ldbl-96 and ldbl-128ibm

Florian Weimer fweimer@redhat.com
Wed Oct 4 13:47:00 GMT 2017


On 10/04/2017 03:15 PM, Joseph Myers wrote:
> On Wed, 4 Oct 2017, H.J. Lu wrote:
> 
>> This is what I checked in.
> 
> This fix doesn't seem to be on 2.26 branch, but needs to go there as the
> original patch went there.
> 
> I don't think using an int count of errors and returning it from do_test
> is a good coding pattern, because if the count reaches 77 it will result
> in a spurious UNSUPPORTED result.  Of course in this particular test it
> can't reach 77, but a better pattern is either a boolean error state (set
> to true rather than using ++, given the warning quoted here), or a count
> but with do_test returning errors != 0.

Agreed.  Note that TEST_VERIFY allows the test to continue after a 
failure, and it also arranges for a non-zero exit status (even across 
fork, but currently not across dlopen).  It's usually a good alternative 
to such error variables.

Thanks,
Florian



More information about the Libc-alpha mailing list