GNU bug report logs - #33144
Replace some loops with str functions

Previous Next

Package: diffutils;

Reported by: "Kapus, Timotej" <timotej.kapus13 <at> imperial.ac.uk>

Date: Wed, 24 Oct 2018 23:43:02 UTC

Severity: normal

Full log


Message #8 received at 33144 <at> debbugs.gnu.org (full text, mbox):

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: "Kapus, Timotej" <timotej.kapus13 <at> imperial.ac.uk>, 33144 <at> debbugs.gnu.org
Cc: "Cadar, Cristian" <c.cadar <at> imperial.ac.uk>
Subject: Re: [bug-diffutils] bug#33144: Replace some loops with str functions
Date: Thu, 25 Oct 2018 12:57:10 -0700
On 10/24/18 4:06 PM, Kapus, Timotej wrote:
> I find strspn easier to read, communicate intention and has less LOC

On the other hand, it's probably slower for this particular use case, 
and the replacement code you wrote is not equivalent to the code it 
replaced because 'c' ends up having a different value.





This bug report was last modified 6 years and 236 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.