Skip to content

Commit 78c12ff

Browse files
Add comment
1 parent 1e710b4 commit 78c12ff

File tree

3 files changed

+3
-0
lines changed

3 files changed

+3
-0
lines changed

Modules/_io/bufferedio.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2440,6 +2440,7 @@ static PyType_Slot bufferediobase_slots[] = {
24402440
{0, NULL},
24412441
};
24422442

2443+
/* Do not set Py_TPFLAGS_HAVE_GC so that tp_traverse and tp_clear are inherited */
24432444
PyType_Spec bufferediobase_spec = {
24442445
.name = "_io._BufferedIOBase",
24452446
.flags = (Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE |

Modules/_io/iobase.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1050,6 +1050,7 @@ static PyType_Slot rawiobase_slots[] = {
10501050
{0, NULL},
10511051
};
10521052

1053+
/* Do not set Py_TPFLAGS_HAVE_GC so that tp_traverse and tp_clear are inherited */
10531054
PyType_Spec rawiobase_spec = {
10541055
.name = "_io._RawIOBase",
10551056
.flags = (Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE |

Modules/_io/textio.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,7 @@ static PyType_Slot textiobase_slots[] = {
190190
{0, NULL},
191191
};
192192

193+
/* Do not set Py_TPFLAGS_HAVE_GC so that tp_traverse and tp_clear are inherited */
193194
PyType_Spec textiobase_spec = {
194195
.name = "_io._TextIOBase",
195196
.flags = (Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE |

0 commit comments

Comments
 (0)