[Bug c/60087] New: Incorrect column number for -Wsign-compare
chengniansun at gmail dot com
gcc-bugzilla@gcc.gnu.org
Thu Feb 6 00:43:00 GMT 2014
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60087
Bug ID: 60087
Summary: Incorrect column number for -Wsign-compare
Product: gcc
Version: 4.9.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: chengniansun at gmail dot com
Incorrect column number in -Wsign-compare warnings. The number always starts
from the head of the statement.
$: cat s.c
const unsigned char g_192 = 0;
unsigned fn1() {
return 0 != ~g_192;
}
$: gcc-trunk -c -Wsign-compare s.c
s.c: In function ‘fn1’:
s.c:3:1: warning: promoted ~unsigned is always non-zero [-Wsign-compare]
return 0 != ~g_192;
^
More information about the Gcc-bugs
mailing list