Cleanup: PyMethodDef formatting

Missed these changes in [0].

Also replace designated initializers in some C code, as it's not used
often and would need to be removed when converting to C++.

[0] e555ede626
This commit is contained in:
2022-11-08 11:13:58 +11:00
parent 3e71220efc
commit 4eb9322eda
38 changed files with 326 additions and 256 deletions

View File

@@ -4621,21 +4621,25 @@ static int props_clear(PyObject *UNUSED(self))
return 0;
}
static struct PyModuleDef props_module = {
PyModuleDef_HEAD_INIT,
"bpy.props",
PyDoc_STRVAR(
props_module_doc,
"This module defines properties to extend Blender's internal data. The result of these "
"functions"
" is used to assign properties to classes registered with Blender and can't be used "
"directly.\n"
"\n"
".. note:: All parameters to these functions must be passed as keywords.\n",
-1, /* multiple "initialization" just copies the module dict. */
props_methods,
NULL,
props_visit,
props_clear,
NULL,
".. note:: All parameters to these functions must be passed as keywords.\n");
static struct PyModuleDef props_module = {
PyModuleDef_HEAD_INIT,
/*m_name*/ "bpy.props",
/*m_doc*/ props_module_doc,
/*m_size*/ -1, /* multiple "initialization" just copies the module dict. */
/*m_methods*/ props_methods,
/*m_slots*/ NULL,
/*m_traverse*/ props_visit,
/*m_clear*/ props_clear,
/*m_free*/ NULL,
};
PyObject *BPY_rna_props(void)