summaryrefslogtreecommitdiffstats
path: root/Objects/classobject.c
diff options
context:
space:
mode:
authorMartin Panter <vadmium+py@gmail.com>2016-06-21 23:58:05 (GMT)
committerMartin Panter <vadmium+py@gmail.com>2016-06-21 23:58:05 (GMT)
commit646b528467b171148143980452d2aa4294cbe5c8 (patch)
tree543a51b71ca637973beeebb3d450d83727496315 /Objects/classobject.c
parent4e6e56536840a7080316bf036b4df799a6601049 (diff)
downloadcpython-646b528467b171148143980452d2aa4294cbe5c8.zip
cpython-646b528467b171148143980452d2aa4294cbe5c8.tar.gz
cpython-646b528467b171148143980452d2aa4294cbe5c8.tar.bz2
Issue #22463: Backport compiler warning fixes and workarounds
* Set but unused variable in Parser/pgen.c in non-debug builds. Patch by Christian Heimes. * Unused static function in Modules/readline.c. Patch by Georg Brandl. * main_window unused in Modules/tkappinit.c. Patch by Gregory P. Smith. * Dead assignment in Modules/_ctypes/cfield.c. Extracted from patch by Brett Cannon. * Expression result unused in PyObject_INIT macro expansions. Based on patches by Christian Heimes. * Load expat_config.h and therefore pyconfig.h before C stdlib headers are loaded. This silences pre-processor warnings including '_POSIX_C_SOURCE redefined'. Extracted from patch by Christian Heimes.
Diffstat (limited to 'Objects/classobject.c')
-rw-r--r--Objects/classobject.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/classobject.c b/Objects/classobject.c
index 636d178..738e613 100644
--- a/Objects/classobject.c
+++ b/Objects/classobject.c
@@ -2256,7 +2256,7 @@ PyMethod_New(PyObject *func, PyObject *self, PyObject *klass)
im = free_list;
if (im != NULL) {
free_list = (PyMethodObject *)(im->im_self);
- PyObject_INIT(im, &PyMethod_Type);
+ (void)PyObject_INIT(im, &PyMethod_Type);
numfree--;
}
else {