Cleanup: replace UNUSED macro with commented args in C++ code
This is the conventional way of dealing with unused arguments in C++, since it works on all compilers. Regex find and replace: `UNUSED\((\w+)\)` -> `/*$1*/`
This commit is contained in:
@@ -193,15 +193,13 @@ PyDoc_STRVAR(FEdgeSharp_normal_right_doc,
|
||||
"\n"
|
||||
":type: :class:`mathutils.Vector`");
|
||||
|
||||
static PyObject *FEdgeSharp_normal_right_get(BPy_FEdgeSharp *self, void *UNUSED(closure))
|
||||
static PyObject *FEdgeSharp_normal_right_get(BPy_FEdgeSharp *self, void * /*closure*/)
|
||||
{
|
||||
return Vector_CreatePyObject_cb(
|
||||
(PyObject *)self, 3, FEdgeSharp_mathutils_cb_index, MATHUTILS_SUBTYPE_NORMAL_A);
|
||||
}
|
||||
|
||||
static int FEdgeSharp_normal_right_set(BPy_FEdgeSharp *self,
|
||||
PyObject *value,
|
||||
void *UNUSED(closure))
|
||||
static int FEdgeSharp_normal_right_set(BPy_FEdgeSharp *self, PyObject *value, void * /*closure*/)
|
||||
{
|
||||
float v[3];
|
||||
if (mathutils_array_parse(v, 3, 3, value, "value must be a 3-dimensional vector") == -1) {
|
||||
@@ -217,13 +215,13 @@ PyDoc_STRVAR(FEdgeSharp_normal_left_doc,
|
||||
"\n"
|
||||
":type: :class:`mathutils.Vector`");
|
||||
|
||||
static PyObject *FEdgeSharp_normal_left_get(BPy_FEdgeSharp *self, void *UNUSED(closure))
|
||||
static PyObject *FEdgeSharp_normal_left_get(BPy_FEdgeSharp *self, void * /*closure*/)
|
||||
{
|
||||
return Vector_CreatePyObject_cb(
|
||||
(PyObject *)self, 3, FEdgeSharp_mathutils_cb_index, MATHUTILS_SUBTYPE_NORMAL_B);
|
||||
}
|
||||
|
||||
static int FEdgeSharp_normal_left_set(BPy_FEdgeSharp *self, PyObject *value, void *UNUSED(closure))
|
||||
static int FEdgeSharp_normal_left_set(BPy_FEdgeSharp *self, PyObject *value, void * /*closure*/)
|
||||
{
|
||||
float v[3];
|
||||
if (mathutils_array_parse(v, 3, 3, value, "value must be a 3-dimensional vector") == -1) {
|
||||
@@ -241,14 +239,14 @@ PyDoc_STRVAR(FEdgeSharp_material_index_right_doc,
|
||||
"\n"
|
||||
":type: int");
|
||||
|
||||
static PyObject *FEdgeSharp_material_index_right_get(BPy_FEdgeSharp *self, void *UNUSED(closure))
|
||||
static PyObject *FEdgeSharp_material_index_right_get(BPy_FEdgeSharp *self, void * /*closure*/)
|
||||
{
|
||||
return PyLong_FromLong(self->fes->aFrsMaterialIndex());
|
||||
}
|
||||
|
||||
static int FEdgeSharp_material_index_right_set(BPy_FEdgeSharp *self,
|
||||
PyObject *value,
|
||||
void *UNUSED(closure))
|
||||
void * /*closure*/)
|
||||
{
|
||||
uint i = PyLong_AsUnsignedLong(value);
|
||||
if (PyErr_Occurred()) {
|
||||
@@ -263,14 +261,14 @@ PyDoc_STRVAR(FEdgeSharp_material_index_left_doc,
|
||||
"\n"
|
||||
":type: int");
|
||||
|
||||
static PyObject *FEdgeSharp_material_index_left_get(BPy_FEdgeSharp *self, void *UNUSED(closure))
|
||||
static PyObject *FEdgeSharp_material_index_left_get(BPy_FEdgeSharp *self, void * /*closure*/)
|
||||
{
|
||||
return PyLong_FromLong(self->fes->bFrsMaterialIndex());
|
||||
}
|
||||
|
||||
static int FEdgeSharp_material_index_left_set(BPy_FEdgeSharp *self,
|
||||
PyObject *value,
|
||||
void *UNUSED(closure))
|
||||
void * /*closure*/)
|
||||
{
|
||||
uint i = PyLong_AsUnsignedLong(value);
|
||||
if (PyErr_Occurred()) {
|
||||
@@ -286,7 +284,7 @@ PyDoc_STRVAR(FEdgeSharp_material_right_doc,
|
||||
"\n"
|
||||
":type: :class:`Material`");
|
||||
|
||||
static PyObject *FEdgeSharp_material_right_get(BPy_FEdgeSharp *self, void *UNUSED(closure))
|
||||
static PyObject *FEdgeSharp_material_right_get(BPy_FEdgeSharp *self, void * /*closure*/)
|
||||
{
|
||||
return BPy_FrsMaterial_from_FrsMaterial(self->fes->aFrsMaterial());
|
||||
}
|
||||
@@ -296,7 +294,7 @@ PyDoc_STRVAR(FEdgeSharp_material_left_doc,
|
||||
"\n"
|
||||
":type: :class:`Material`");
|
||||
|
||||
static PyObject *FEdgeSharp_material_left_get(BPy_FEdgeSharp *self, void *UNUSED(closure))
|
||||
static PyObject *FEdgeSharp_material_left_get(BPy_FEdgeSharp *self, void * /*closure*/)
|
||||
{
|
||||
return BPy_FrsMaterial_from_FrsMaterial(self->fes->bFrsMaterial());
|
||||
}
|
||||
@@ -308,14 +306,14 @@ PyDoc_STRVAR(FEdgeSharp_face_mark_right_doc,
|
||||
"\n"
|
||||
":type: bool");
|
||||
|
||||
static PyObject *FEdgeSharp_face_mark_right_get(BPy_FEdgeSharp *self, void *UNUSED(closure))
|
||||
static PyObject *FEdgeSharp_face_mark_right_get(BPy_FEdgeSharp *self, void * /*closure*/)
|
||||
{
|
||||
return PyBool_from_bool(self->fes->aFaceMark());
|
||||
}
|
||||
|
||||
static int FEdgeSharp_face_mark_right_set(BPy_FEdgeSharp *self,
|
||||
PyObject *value,
|
||||
void *UNUSED(closure))
|
||||
void * /*closure*/)
|
||||
{
|
||||
if (!PyBool_Check(value)) {
|
||||
return -1;
|
||||
@@ -329,14 +327,12 @@ PyDoc_STRVAR(FEdgeSharp_face_mark_left_doc,
|
||||
"\n"
|
||||
":type: bool");
|
||||
|
||||
static PyObject *FEdgeSharp_face_mark_left_get(BPy_FEdgeSharp *self, void *UNUSED(closure))
|
||||
static PyObject *FEdgeSharp_face_mark_left_get(BPy_FEdgeSharp *self, void * /*closure*/)
|
||||
{
|
||||
return PyBool_from_bool(self->fes->bFaceMark());
|
||||
}
|
||||
|
||||
static int FEdgeSharp_face_mark_left_set(BPy_FEdgeSharp *self,
|
||||
PyObject *value,
|
||||
void *UNUSED(closure))
|
||||
static int FEdgeSharp_face_mark_left_set(BPy_FEdgeSharp *self, PyObject *value, void * /*closure*/)
|
||||
{
|
||||
if (!PyBool_Check(value)) {
|
||||
return -1;
|
||||
|
||||
Reference in New Issue
Block a user