http://llvm.org/bugs/show_bug.cgi?id=9987
Summary: -Wextra overrides earlier -Wno-sign-compare
Product: clang
Version: trunk
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P
Component: Driver
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected]
For GCC, the -Wall and -Wextra (aka -W) options are supposed to set the warning
defaults and -Wno-* can be used to disable options again. This doesn't work as
expected with clang.
Consider the following input:
int main(void)
{
int a = 0;
unsigned int b = 1;
return a < b ? 1 : 2;
}
clang -Wextra -Wno-sign-compare -c test.c
is silent.
clang -Wno-sign-compare -Wextra -c test.c
warns, when it should be silent (and the diagnostic message is kind of
confusion).
GCC doesn't warn in either case.
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs