An invalid expression as parameter
Terry Reedy
tjreedy at udel.edu
Mon Jun 28 18:15:10 EDT 2010
On 6/28/2010 10:49 AM, Stephen Hansen wrote:
> Now, if you are entering a generator where its not 'on its own' and its
> not ambiguous-- such as inside a function call-- you don't have to
> surround it by its own parens. So you don't have to do f((i for i in
> range(4)).
You need another ) on the end. That illustrates why the devs allowed one
() to be omitted ;-)
--
Terry Jan Reedy
More information about the Python-list
mailing list