Skip to content

Commit 8d17ef3

Browse files
committed
Update comment relating to Py_XNewRef in BaseExceptionGroup_repr()
1 parent 737206a commit 8d17ef3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Objects/exceptions.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1088,7 +1088,8 @@ BaseExceptionGroup_repr(PyObject *op)
10881088

10891089
PyObject *exceptions_str = Py_XNewRef(self->excs_str);
10901090

1091-
/* If the initial exceptions string was not saved in the constructor. */
1091+
/* If the initial exceptions string was not saved in the constructor,
1092+
* our call to Py_XNewRef returns NULL and we now format it on-demand. */
10921093
if (!exceptions_str) {
10931094
assert(self->excs);
10941095

0 commit comments

Comments
 (0)