Are multiple return values really harmful? (Re: determining the number of output arguments)
Bengt Richter
bokr at oz.net
Thu Nov 18 22:40:30 EST 2004
On Thu, 18 Nov 2004 11:16:31 -0800, Jeff Shannon <jeff at ccvcorp.com> wrote:
>Bengt Richter wrote:
>
>>Maybe keyword unpacking could spell that with a '**' assignment target,
>>e.g.,
>>
>> ** = foo() # update local bindings with all legal-name bindings in returned dict
>>
>>
>
>I would *not* like to see this. ISTM that, when reading a function, I
>should be able to see where every name in that function came from.
>Having global values appear from outside of the function is bad enough;
>introducing a new way to magically create variables whose names I can't
^^^^^^
Not create, just rebind existing locals.
>see would be (IMO) very, very bad.
All things in moderation. But I agree that you would have to know and trust foo ;-)
Regards,
Bengt Richter
More information about the Python-list
mailing list