11 messages in com.googlegroups.sqlalchemy[sqlalchemy] Re: any particular reaso...
FromSent OnAttachments
sdob...@sistechnology.com25 Jan 2007 13:29 
Jonathan Ellis25 Jan 2007 13:58 
Michael Bayer25 Jan 2007 14:03 
svilen30 Jan 2007 01:34 
svilen31 Jan 2007 10:28 
Michael Bayer31 Jan 2007 11:21 
sdob...@sistechnology.com31 Jan 2007 17:19 
Michael Bayer03 Feb 2007 17:20 
sdob...@sistechnology.com04 Feb 2007 00:42.bz2
Michael Bayer04 Feb 2007 13:16 
svilen05 Feb 2007 01:20 
Subject:[sqlalchemy] Re: any particular reason for creating unused lists?
From:Michael Bayer (zzz@gmail.com)
Date:01/25/2007 02:03:29 PM
List:com.googlegroups.sqlalchemy

just habit ...i dont like one liners with ":", also makes it easy to tack on conditionals...feel free to submit a patch for all those if theyre really bothering you (i guarantee program speed /mem usage will not budge in any measurable way).

On Jan 25, 4:30 pm, sdob@sistechnology.com wrote:

there are several places of such unused lists being made.

i pick a random occurence, in this case InstrumentedAttribute:

def _adapt_list(self, data): if self.typecallable is not None: t = self.typecallable() if data is not None: [t.append(x) for x in data] return t else: return data

why not just for x in data: t.append(x)