Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitccf1994

Browse files
committed
Better document super call
1 parent774d02c commitccf1994

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

‎src/_macosx.m‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -572,7 +572,7 @@ bool mpl_check_modifier(bool present, PyObject* list, char const* name)
572572
},
573573
};
574574

575-
static PyTypeObject FigureManagerType;
575+
static PyTypeObject FigureManagerType;// forward declaration, needed in destroy()
576576

577577
typedefstruct {
578578
PyObject_HEAD
@@ -689,7 +689,8 @@ bool mpl_check_modifier(bool present, PyObject* list, char const* name)
689689
[self->windowclose];
690690
self->window =NULL;
691691

692-
// call super().destroy()
692+
// call super(self, FigureManager).destroy() - it seems we need the
693+
// explicit arguments, and just super() doesn't work in the C API.
693694
PyObject *super_obj =PyObject_CallFunctionObjArgs(
694695
(PyObject *)&PySuper_Type,
695696
(PyObject *)&FigureManagerType,

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp