Message267881
Building Python with clang and ccache produces about 200 'parentheses-equality' warnings with the message:
warning: equality comparison with extraneous parentheses [-Wparentheses-equality]
It seems that clang does not recognize that these extraneous parentheses are valid [1] after a macro expansion because the preprocessing is done as a separate stage by ccache.
[1] For example:
With the macros:
#define Py_TYPE(ob) (((PyObject*)(ob))->ob_type)
#define PyLong_CheckExact(op) (Py_TYPE(op) == &PyLong_Type)
The statement:
if (PyLong_CheckExact(v))
is expanded to:
if (((((PyObject*)(v))->ob_type) == &PyLong_Type))
and produces the warning with ccache. |
|
Date |
User |
Action |
Args |
2016-06-08 19:47:43 | xdegaye | set | recipients:
+ xdegaye, ncoghlan, ezio.melotti, eric.araujo, willingc |
2016-06-08 19:47:43 | xdegaye | set | messageid: <1465415263.12.0.159795814979.issue27270@psf.upfronthosting.co.za> |
2016-06-08 19:47:43 | xdegaye | link | issue27270 messages |
2016-06-08 19:47:42 | xdegaye | create | |
|