Cleanup: compiler warnings
This commit is contained in:
@@ -373,7 +373,7 @@ TEST(string, StrFormatUint64Grouped)
|
||||
BLI_str_format_uint64_grouped(number_str, number = 1000);
|
||||
EXPECT_STREQ("1,000", number_str);
|
||||
|
||||
BLI_str_format_uint64_grouped(number_str, number = 18446744073709551615);
|
||||
BLI_str_format_uint64_grouped(number_str, number = 18446744073709551615u);
|
||||
EXPECT_STREQ("18,446,744,073,709,551,615", number_str);
|
||||
}
|
||||
|
||||
|
||||
@@ -146,7 +146,7 @@ Object **ED_object_array_in_mode_or_selected(bContext *C,
|
||||
ID *id_pin = nullptr;
|
||||
const bool use_objects_in_mode = (ob_active != nullptr) &&
|
||||
(ob_active->mode & (OB_MODE_EDIT | OB_MODE_POSE));
|
||||
const char space_type = area ? area->spacetype : SPACE_EMPTY;
|
||||
const eSpace_Type space_type = area ? eSpace_Type(area->spacetype) : SPACE_EMPTY;
|
||||
Object **objects;
|
||||
|
||||
Object *ob = nullptr;
|
||||
|
||||
@@ -1205,36 +1205,48 @@ static PyObject *C_BVHTree_FromObject(PyObject * /*cls*/, PyObject *args, PyObje
|
||||
/** \name Module & Type definition
|
||||
* \{ */
|
||||
|
||||
#ifdef __GNUC__
|
||||
# pragma GCC diagnostic push
|
||||
# pragma GCC diagnostic ignored "-Wcast-function-type"
|
||||
#endif
|
||||
|
||||
static PyMethodDef py_bvhtree_methods[] = {
|
||||
{"ray_cast", (PyCFunction)py_bvhtree_ray_cast, METH_VARARGS, py_bvhtree_ray_cast_doc},
|
||||
{"ray_cast",
|
||||
reinterpret_cast<PyCFunction>(py_bvhtree_ray_cast),
|
||||
METH_VARARGS,
|
||||
py_bvhtree_ray_cast_doc},
|
||||
{"find_nearest",
|
||||
(PyCFunction)py_bvhtree_find_nearest,
|
||||
reinterpret_cast<PyCFunction>(py_bvhtree_find_nearest),
|
||||
METH_VARARGS,
|
||||
py_bvhtree_find_nearest_doc},
|
||||
{"find_nearest_range",
|
||||
(PyCFunction)py_bvhtree_find_nearest_range,
|
||||
reinterpret_cast<PyCFunction>(py_bvhtree_find_nearest_range),
|
||||
METH_VARARGS,
|
||||
py_bvhtree_find_nearest_range_doc},
|
||||
{"overlap", (PyCFunction)py_bvhtree_overlap, METH_O, py_bvhtree_overlap_doc},
|
||||
{"overlap", reinterpret_cast<PyCFunction>(py_bvhtree_overlap), METH_O, py_bvhtree_overlap_doc},
|
||||
|
||||
/* class methods */
|
||||
{"FromPolygons",
|
||||
(PyCFunction)C_BVHTree_FromPolygons,
|
||||
reinterpret_cast<PyCFunction>(C_BVHTree_FromPolygons),
|
||||
METH_VARARGS | METH_KEYWORDS | METH_CLASS,
|
||||
C_BVHTree_FromPolygons_doc},
|
||||
#ifndef MATH_STANDALONE
|
||||
{"FromBMesh",
|
||||
(PyCFunction)C_BVHTree_FromBMesh,
|
||||
reinterpret_cast<PyCFunction>(C_BVHTree_FromBMesh),
|
||||
METH_VARARGS | METH_KEYWORDS | METH_CLASS,
|
||||
C_BVHTree_FromBMesh_doc},
|
||||
{"FromObject",
|
||||
(PyCFunction)C_BVHTree_FromObject,
|
||||
reinterpret_cast<PyCFunction>(C_BVHTree_FromObject),
|
||||
METH_VARARGS | METH_KEYWORDS | METH_CLASS,
|
||||
C_BVHTree_FromObject_doc},
|
||||
#endif
|
||||
{nullptr, nullptr, 0, nullptr},
|
||||
};
|
||||
|
||||
#ifdef __GNUC__
|
||||
# pragma GCC diagnostic pop
|
||||
#endif
|
||||
|
||||
PyTypeObject PyBVHTree_Type = {
|
||||
PyVarObject_HEAD_INIT(nullptr, 0)
|
||||
/*tp_name*/ "BVHTree",
|
||||
|
||||
Reference in New Issue
Block a user