Skip to content

Commit 406f674

Browse files
committed
gh-154997: Move raw_access_safe outside Clinic block
1 parent 559722f commit 406f674

1 file changed

Lines changed: 10 additions & 10 deletions

File tree

Modules/_io/bufferedio.c

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -471,16 +471,6 @@ buffered_traverse(PyObject *op, visitproc visit, void *arg)
471471
return 0;
472472
}
473473

474-
/* Because this can call arbitrary code, it shouldn't be called when
475-
the refcount is 0 (that is, not directly from tp_dealloc unless
476-
the refcount has been temporarily re-incremented). */
477-
/*[clinic input]
478-
_io._Buffered._dealloc_warn
479-
480-
source: object
481-
/
482-
483-
[clinic start generated code]*/
484474
static PyObject *
485475
raw_access_safe(buffered *self)
486476
{
@@ -504,6 +494,16 @@ raw_access_safe(buffered *self)
504494
return self->raw;
505495
}
506496

497+
/* Because this can call arbitrary code, it shouldn't be called when
498+
the refcount is 0 (that is, not directly from tp_dealloc unless
499+
the refcount has been temporarily re-incremented). */
500+
/*[clinic input]
501+
_io._Buffered._dealloc_warn
502+
503+
source: object
504+
/
505+
506+
[clinic start generated code]*/
507507
static PyObject *
508508
_io__Buffered__dealloc_warn_impl(buffered *self, PyObject *source)
509509
/*[clinic end generated code: output=d8db21c6dec0e614 input=8f845f2a4786391c]*/

0 commit comments

Comments
 (0)