[Python-Dev] Re: PEP 642: Constraint Pattern Syntax for Structural Pattern Matching

2020年10月31日 08:06:05 -0700

Hello,
On 2020年10月31日 12:16:09 +0000
Paul Moore <[email protected]> wrote:
> On 2020年10月31日 at 11:25, Steven D'Aprano <[email protected]>
> wrote:
> >
> > Thank you for the well-written PEP, although I don't agree with it.
> > My response below is quite long. Here is my opinionated TL;DR: 
> 
> For what it's worth, I find your rebuttal of PEP 642 convincing, and
> in line with my thoughts on the matter.
> 
> -1 from me on PEP 642.
Given that this was a direct reply to Steven's mail, and he explicitly
said:
> (4) Using sigils to over-ride the default is okay. That includes
> turning what would otherwise be a capture pattern into a comparison.
And that's also the stated goal of PEP 642, quoting:
> This PEP takes the view that not requiring a marker prefix on value
> lookups in match patterns results in a cure that is worse than the
> disease: Python's first ever syntax-sensitive value lookup where you
> can't transparently replace an attribute lookup with a local variable
> lookup
So, both PEP 642 and Steven agree that the problem exists, and explicit
marker is a suitable means to address it.
Then, deriving "rebuttal" and "-1" to PEP 642 from Steven's mail sounds
a bit confusing.
-- 
Best regards,
 Paul mailto:[email protected]
_______________________________________________
Python-Dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/[email protected]/message/4GXMELBO6HCXCYWKPQAXOSSC6ZD7Y2ZV/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to