This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/61081] excessive warnings: right-hand operand of comma expression has no effect


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=61081

Manuel LÃpez-IbÃÃez <manu at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |manu at gcc dot gnu.org

--- Comment #5 from Manuel LÃpez-IbÃÃez <manu at gcc dot gnu.org> ---
Apple should mark their system headers as such using:

#pragma GCC system_header

Other compilers will ignore this pragma.

You could do that simply by adding a dummy header that includes the real
header. Or you can just disable the warning in your code with #pragma GCC
diagnostic ignore "Wwhatever".

We could also not warn if the right-hand operand comes from the macro
definition, but I am not sure how difficult is to do that and whether it is
really worth the effort.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]