mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
gh-113602: Bail out when the parser tries to override existing errors (#113607)
Signed-off-by: Pablo Galindo <pablogsal@gmail.com>
This commit is contained in:
parent
8ff44f8554
commit
9ed36d533a
3 changed files with 8 additions and 0 deletions
|
@ -2360,6 +2360,8 @@ func(
|
|||
"""
|
||||
self._check_error(code, "parenthesis '\\)' does not match opening parenthesis '\\['")
|
||||
|
||||
self._check_error("match y:\n case e(e=v,v,", " was never closed")
|
||||
|
||||
# Examples with dencodings
|
||||
s = b'# coding=latin\n(aaaaaaaaaaaaaaaaa\naaaaaaaaaaa\xb5'
|
||||
self._check_error(s, r"'\(' was never closed")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue