[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18159] branches/blender2.5/blender/source /blender/python/intern/bpy_operator.c: 2.5
Nathan Letwory
jesterking at letwory.net
Tue Dec 30 01:35:34 CET 2008
Revision: 18159
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18159
Author: jesterking
Date: 2008-12-30 01:35:31 +0100 (Tue, 30 Dec 2008)
Log Message:
-----------
2.5
* make bpy compile with msvc again. The forward declaration of the array with no length was a problem. Instead, I switched the tables and made the function a forward declaration.
Modified Paths:
--------------
branches/blender2.5/blender/source/blender/python/intern/bpy_operator.c
Modified: branches/blender2.5/blender/source/blender/python/intern/bpy_operator.c
===================================================================
--- branches/blender2.5/blender/source/blender/python/intern/bpy_operator.c 2008-12-30 00:31:45 UTC (rev 18158)
+++ branches/blender2.5/blender/source/blender/python/intern/bpy_operator.c 2008-12-30 00:35:31 UTC (rev 18159)
@@ -223,8 +223,15 @@
Py_RETURN_NONE;
}
-static struct PyMethodDef pyop_base_methods[];
+PyObject *pyop_base_dir(PyObject *self);
+static struct PyMethodDef pyop_base_methods[] = {
+ {"add", (PyCFunction)PYOP_wrap_add, METH_VARARGS, ""},
+ {"remove", (PyCFunction)PYOP_wrap_remove, METH_VARARGS, ""},
+ {"__dir__", (PyCFunction)pyop_base_dir, METH_NOARGS, ""},
+ {NULL, NULL, 0, NULL}
+};
+
PyObject *pyop_base_dir(PyObject *self)
{
PyObject *ret = PyList_New(0);
@@ -247,13 +254,6 @@
return ret;
}
-static struct PyMethodDef pyop_base_methods[] = {
- {"add", (PyCFunction)PYOP_wrap_add, METH_VARARGS, ""},
- {"remove", (PyCFunction)PYOP_wrap_remove, METH_VARARGS, ""},
- {"__dir__", (PyCFunction)pyop_base_dir, METH_NOARGS, ""},
- {NULL, NULL, 0, NULL}
-};
-
/*-----------------------BPy_OperatorBase method def------------------------------*/
PyTypeObject pyop_base_Type = {
#if (PY_VERSION_HEX >= 0x02060000)
More information about the Bf-blender-cvs
mailing list