Add an explicit cast to (void*) and add Py_UNUSED() to fix some
warnings in extension.c.
static int
-_testcext_exec(PyObject *module)
+_testcext_exec(
+#ifdef __STDC_VERSION__
+ PyObject *module
+#else
+ PyObject *Py_UNUSED(module)
+#endif
+ )
{
#ifdef __STDC_VERSION__
if (PyModule_AddIntMacro(module, __STDC_VERSION__) < 0) {
}
static PyModuleDef_Slot _testcext_slots[] = {
- {Py_mod_exec, _testcext_exec},
+ {Py_mod_exec, (void*)_testcext_exec},
{0, NULL}
};
else:
# MSVC compiler flags
CFLAGS = [
+ # Display warnings level 1 to 4
+ '/W4',
# Treat all compiler warnings as compiler errors
'/WX',
]
else:
# MSVC compiler flags
CPPFLAGS = [
+ # Display warnings level 1 to 4
+ '/W4',
# Treat all compiler warnings as compiler errors
'/WX',
]