File tree Expand file tree Collapse file tree 2 files changed +0
-8
lines changed Expand file tree Collapse file tree 2 files changed +0
-8
lines changed Original file line number Diff line number Diff line change @@ -345,11 +345,7 @@ struct type_record {
345
345
346
346
bases.append ((PyObject *) base_info->type );
347
347
348
- #if PY_VERSION_HEX < 0x030B0000
349
348
dynamic_attr |= base_info->type ->tp_dictoffset != 0 ;
350
- #else
351
- dynamic_attr |= (base_info->type ->tp_flags & Py_TPFLAGS_MANAGED_DICT) != 0 ;
352
- #endif
353
349
354
350
if (caster) {
355
351
base_info->implicit_casts .emplace_back (type, caster);
Original file line number Diff line number Diff line change @@ -549,12 +549,8 @@ extern "C" inline int pybind11_clear(PyObject *self) {
549
549
inline void enable_dynamic_attributes (PyHeapTypeObject *heap_type) {
550
550
auto *type = &heap_type->ht_type ;
551
551
type->tp_flags |= Py_TPFLAGS_HAVE_GC;
552
- #if PY_VERSION_HEX < 0x030B0000
553
552
type->tp_dictoffset = type->tp_basicsize ; // place dict at the end
554
553
type->tp_basicsize += (ssize_t ) sizeof (PyObject *); // and allocate enough space for it
555
- #else
556
- type->tp_flags |= Py_TPFLAGS_MANAGED_DICT;
557
- #endif
558
554
type->tp_traverse = pybind11_traverse;
559
555
type->tp_clear = pybind11_clear;
560
556
You can’t perform that action at this time.
0 commit comments