Cleanup: avoid error-prone function cast

This commit is contained in:
Jacques Lucke
2025-04-08 09:54:39 +02:00
parent 6f022e0530
commit d8a959f34a

View File

@@ -59,11 +59,11 @@ static BPy_GeometrySet *python_object_from_geometry_set(GeometrySet geometry = {
return self;
}
static BPy_GeometrySet *BPy_GeometrySet_new(PyTypeObject * /*type*/,
PyObject * /*args*/,
PyObject * /*kwds*/)
static PyObject *BPy_GeometrySet_new(PyTypeObject * /*type*/,
PyObject * /*args*/,
PyObject * /*kwds*/)
{
return python_object_from_geometry_set();
return reinterpret_cast<PyObject *>(python_object_from_geometry_set());
}
static void BPy_GeometrySet_dealloc(BPy_GeometrySet *self)
@@ -472,7 +472,7 @@ PyTypeObject bpy_geometry_set_Type = {
/*tp_dictoffset*/ 0,
/*tp_init*/ nullptr,
/*tp_alloc*/ nullptr,
/*tp_new*/ reinterpret_cast<newfunc>(BPy_GeometrySet_new),
/*tp_new*/ BPy_GeometrySet_new,
};
PyObject *BPyInit_geometry_set_type()