summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_exceptions.py
diff options
context:
space:
mode:
authorPablo Galindo Salgado <Pablogsal@gmail.com>2021-11-20 17:39:17 (GMT)
committerGitHub <noreply@github.com>2021-11-20 17:39:17 (GMT)
commit511ee1c0fa4dedf32cc2b9f9fa13aa61e07bd165 (patch)
tree8eba6bc238085ac83d27012c4fcfee0705aa00e6 /Lib/test/test_exceptions.py
parent82f1a6edfb645abef934ae1b568dd887ff7a56b9 (diff)
downloadcpython-511ee1c0fa4dedf32cc2b9f9fa13aa61e07bd165.zip
cpython-511ee1c0fa4dedf32cc2b9f9fa13aa61e07bd165.tar.gz
cpython-511ee1c0fa4dedf32cc2b9f9fa13aa61e07bd165.tar.bz2
[3.10] bpo-45727: Make the syntax error for missing comma more consistent (GH-29427) (GH-29647)
(cherry picked from commit 546cefcda75d7150b55c8bc1724bea35a1e12890) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
Diffstat (limited to 'Lib/test/test_exceptions.py')
-rw-r--r--Lib/test/test_exceptions.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/test/test_exceptions.py b/Lib/test/test_exceptions.py
index 04c883c..4c18a59 100644
--- a/Lib/test/test_exceptions.py
+++ b/Lib/test/test_exceptions.py
@@ -226,13 +226,14 @@ class ExceptionTests(unittest.TestCase):
check(b'Python = "\xcf\xb3\xf2\xee\xed" +', 1, 18)
check('x = "a', 1, 5)
check('lambda x: x = 2', 1, 1)
- check('f{a + b + c}', 1, 2)
+ check('f{a + b + c}', 1, 1)
check('[file for str(file) in []\n])', 1, 11)
check('a = « hello » « world »', 1, 5)
check('[\nfile\nfor str(file)\nin\n[]\n]', 3, 5)
check('[file for\n str(file) in []]', 2, 2)
check("ages = {'Alice'=22, 'Bob'=23}", 1, 16)
check('match ...:\n case {**rest, "key": value}:\n ...', 2, 19)
+ check("a b c d e f", 1, 1)
# Errors thrown by compile.c
check('class foo:return 1', 1, 11)