This is the mail archive of the gcc-cvs@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]

r242472 - in /trunk/gcc/testsuite: ChangeLog c-...


Author: saaadhu
Date: Wed Nov 16 09:28:40 2016
New Revision: 242472

URL: https://gcc.gnu.org/viewcvs?rev=242472&root=gcc&view=rev
Log:
Fix bogus failure of Wlogical-op-1.c for avr

The test assumes short is always smaller than int, and therefore does not 
expect a warning when the logical operands are of type short and int.

This isn't true for the avr - shorts and ints are of the same size, and
therefore the warning triggers for the above case also.

Fix by explicitly typedef'ing __INT32_TYPE for int and __INT16_TYPE__ for short
if the target's int size is less than 4 bytes.

gcc/testsuite/
2016-11-16  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>

	* c-c++-common/Wlogical-op-1.c: Use __INT{16,32}_TYPE__ instead
	of {short,int} if __SIZEOF_INT__ is less than 4 bytes.

Modified:
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/testsuite/c-c++-common/Wlogical-op-1.c


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