[Yum-devel] Re: [yum-cvs] yum/yum packageSack.py, 1.6, 1.7 packages.py, 1.51, 1.52
Luke Macken
lmacken at redhat.com
Tue Aug 22 18:16:37 UTC 2006
On Tue, Aug 22, 2006 at 01:28:04PM -0400, Jeremy Katz wrote:
> Style question only...
>
> On Tue, 2006-08-22 at 00:04 -0400, Seth Vidal wrote:
> > + def __lt__(self, other):
> > + val = False
> > + rc = comparePoEVR(self, other)
> > + if rc < 0:
> > + val = True
> > +
> > + return val
>
> Does it make more sense to do
> def __lt__(self, other):
> if comparePoEVR(self, other) < 0:
> return True
> return False
>
> instead? It's more compact and so a little easier for me to read, but I
> doubt it has any real effect beyond aesthetics.
or, compacting things a bit more :)
def __lt__(self, other):
return comparePoEVR(self, other) < 0
luke
More information about the Yum-devel
mailing list