On Sun, 10 Jan 2021, 12:54 am Nick Coghlan, <ncogh...@gmail.com> wrote:

>
>
> On Sun, 10 Jan 2021, 12:22 am Paul Moore, <p.f.mo...@gmail.com> wrote:
>
>> On Sat, 9 Jan 2021 at 13:53, Antoine Pitrou <anto...@python.org> wrote:
>>
>>
>> The dictionary destructuring can act as an example. We know Nick's
>> position:
>>
>>     case {"text": message, "color": c}:
>>
>> 1. There's nothing (other than the fact that it's in a case clause) to
>> indicate that message and c are assigned to.
>> 2. It "binds to the right without using as", (as far as I can see,
>> based on the premise that "as" is the only valid way of binding names
>> where the name is on the right, which was asserted without any
>> justification).
>>
>
> What other syntax do we have that binds to the right without "as"?
> Allowing it at all is only as old as with statements, but that's still more
> precedence than ":" and "=" have for being used that way.
>

Correcting myself: the import statement usage has been around much longer
than that.

With statements were just the case that took 'as name' from being an import
specific syntax to being a bit more general than that.

Cheers,
Nick.


>>
_______________________________________________
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/CSW5HIN3WBEXYECBFZ7ZRH4KLXODLZTD/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to