Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions src/_uarray_dispatch.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -303,8 +303,9 @@ struct BackendState {
bool use_thread_local_globals = true;

static void dealloc(BackendState * self) {
auto tp_free = Py_TYPE(self)->tp_free;
self->~BackendState();
Py_TYPE(self)->tp_free(self);
tp_free(self);
}

static PyObject * new_(
Expand Down Expand Up @@ -754,8 +755,9 @@ struct SetBackendContext {

static void dealloc(SetBackendContext * self) {
PyObject_GC_UnTrack(self);
auto tp_free = Py_TYPE(self)->tp_free;
self->~SetBackendContext();
Py_TYPE(self)->tp_free(self);
tp_free(self);
}

static PyObject * new_(
Expand Down Expand Up @@ -852,8 +854,9 @@ struct SkipBackendContext {

static void dealloc(SkipBackendContext * self) {
PyObject_GC_UnTrack(self);
auto tp_free = Py_TYPE(self)->tp_free;
self->~SkipBackendContext();
Py_TYPE(self)->tp_free(self);
tp_free(self);
}

static PyObject * new_(
Expand Down Expand Up @@ -1077,8 +1080,9 @@ struct Function {

static void dealloc(Function * self) {
PyObject_GC_UnTrack(self);
auto tp_free = Py_TYPE(self)->tp_free;
self->~Function();
Py_TYPE(self)->tp_free(self);
tp_free(self);
}

static PyObject * new_(
Expand Down
Loading