Skip to content

Commit c820de5

Browse files
committed
python#15923: fix a mistake in asdl_c.py that resulted in a TypeError after 2801bf875a24 (see python#15801).
1 parent 2fbe856 commit c820de5

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

‎Misc/NEWS‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -430,6 +430,9 @@ Tests
430430
Build
431431
-----
432432

433+
- Issue #15923: fix a mistake in asdl_c.py that resulted in a TypeError after
434+
2801bf875a24 (see #15801).
435+
433436
- Issue #11715: Fix multiarch detection without having Debian development
434437
tools (dpkg-dev) installed.
435438

‎Parser/asdl_c.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1033,7 +1033,7 @@ def simpleSum(self, sum, name):
10331033
self.emit("case %s:" % t.name, 2)
10341034
self.emit("Py_INCREF(%s_singleton);" % t.name, 3)
10351035
self.emit("return %s_singleton;" % t.name, 3)
1036-
self.emit("default:" % name, 2)
1036+
self.emit("default:", 2)
10371037
self.emit('/* should never happen, but just in case ... */', 3)
10381038
code = "PyErr_Format(PyExc_SystemError, \"unknown %s found\");" % name
10391039
self.emit(code, 3, reflow=False)

0 commit comments

Comments
 (0)