[Python-3000] find -> index patch

Steven Bethard steven.bethard at gmail.com
Thu Aug 24 08:31:54 CEST 2006


On 8/23/06, Jack Diederich <jack at psynchronous.com> wrote:
> On Wed, Aug 23, 2006 at 02:18:59PM -0700, Guido van Rossum wrote:
> > Here's the patch (by Hasan Diwan, BTW) for people's perusal. It just
> > gets rid of all *uses* of find/rfind from Lib; it doesn't actually
> > modify stringobject.c or unicodeobject.c. It doesn't use
> > [r]partition()'; someone could look for opportunities to use that
> > separately.
>
> I make a go at doing an idiomatic convertion of the first few modules
> tagged by 'grep find( *.py' in Lib, patch attached.
>
> WOW, I love partition.

After looking at your patch, I have to agree.  The new code is *way*
more readable.

Nice work!

STeVe
-- 
I'm not *in*-sane. Indeed, I am so far *out* of sane that you appear a
tiny blip on the distant coast of sanity.
        --- Bucky Katt, Get Fuzzy


More information about the Python-3000 mailing list