> > >> indexer.py:
> > >>
> > >>   - line 396: Is this redundant?  Or is fmri_list not a list?  If not,
> > >>     should we name it something less confusing?
> > >>   
> > > What ends up reaching there is a generator of fmris. I'm fine with 
> > > changing 
> > > it. Would 'fmris' work?
> > 
> > Ah, I somehow missed that.  How about fmri_gen, or something that
> > indicates it's a generator function?
> 
> Please don't.  If you treat it as an iterable, you should be able to pass
> in a list, a set, a tuple, a generator, whatever, and giving it a name
> based on what its type is is silly.  We've done this way too much already.
> 
> If it's not clear what it is, beef up the docstring.

The problem is that this code doesn't treat the thing it calls a list as
an iterable.  It calls list(fmri_list) on the object and then proceeds
to treat it as a list.  You don't call list() on an actual list; there's
an implicit assumption here about what this thing is, and it isn't
described by the name of the variable or the docstring.  If you're
opposed to calling it a generator, fine.  However, I don't think list is
accurate either.  Fmri_iter, perhaps?

-j
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss

Reply via email to