Commit 5a93e8de by Joseph Myers Committed by Roger Sayle

compare8.c: New test case.


	* gcc.dg/compare8.c: New test case.

Co-Authored-By: Roger Sayle <roger@eyesopen.com>

From-SVN: r79891
parent cba4497d
2004-03-23 Joseph S. Myers <jsm@polyomino.org.uk>
Roger Sayle <roger@eyesopen.com>
* gcc.dg/compare8.c: New test case.
2004-03-23 Ziemowit Laski <zlaski@apple.com>
* g++.dg/ext/altivec-7.C: New test.
......
/* { dg-do compile } */
/* { dg-options "-Wsign-compare" } */
int
f(unsigned short a1, unsigned short a2, unsigned int b)
{
return ((a1+a2)|5) > b ? 2 : 3; /* { dg-bogus "signed and unsigned" } */
}
int
g(unsigned short a1, unsigned short a2, unsigned int b)
{
return ((a1+a2)&5) > b ? 2 : 3; /* { dg-bogus "signed and unsigned" } */
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment