GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||
GeezerVison is showing github.com — Improve `SyntaxError` message for `case ... as a.b` · Issue #123562 · python/cpython Closed Labels interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)topic-parsertype-featureA feature request or enhancementA feature request or enhancement DescriptionFeature or enhancementThere's already a similar rule: Line 1378 in 084e0f3
But, it has two problems:
My proposed change: Why is it safe? Here's how the parent rule is defined: So, if Proposed result: >>> match 1: ... case x as a.b: ... ... File "<python-input-0>", line 2 case x as a.b: ... ^^^ SyntaxError: cannot use pattern target as attribute Refs #123440 Linked PRsActivity
MetadataMetadataAssigneesLabelsinterpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)topic-parsertype-featureA feature request or enhancementA feature request or enhancement ProjectsMilestoneRelationshipsDevelopmentIssue actions | ||
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |