r267299 - in /trunk/gcc: c-family/ChangeLog c-f...

dmalcolm@gcc.gnu.org dmalcolm@gcc.gnu.org
Thu Dec 20 14:18:00 GMT 2018


Author: dmalcolm
Date: Thu Dec 20 14:18:48 2018
New Revision: 267299

URL: https://gcc.gnu.org/viewcvs?rev=267299&root=gcc&view=rev
Log:
-Wtautological-compare: fix comparison of macro expansions

gcc/c-family/ChangeLog:
	PR c++/87504
	* c-warn.c (get_outermost_macro_expansion): New function.
	(spelled_the_same_p): Use it to unwind the macro expansions, and
	compare the outermost macro in each nested expansion, rather than
	the innermost.

gcc/testsuite/ChangeLog:
	PR c++/87504
	* c-c++-common/Wtautological-compare-8.c: New test.


Added:
    trunk/gcc/testsuite/c-c++-common/Wtautological-compare-8.c
Modified:
    trunk/gcc/c-family/ChangeLog
    trunk/gcc/c-family/c-warn.c
    trunk/gcc/testsuite/ChangeLog



More information about the Gcc-cvs mailing list