http://llvm.org/bugs/show_bug.cgi?id=6004
Summary: clang does not generate a warning for division by zero.
Product: clang
Version: trunk
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
Component: Semantic Analyzer
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected]
gcc generates a warning
C16-115-1.c:7: warning: division by zero
for the following code:
char *pc = (char *) 0xA0;
volatile signed char char1 = 0xFF;
int main(void)
{
if ( char1 % 0) {
*pc = 1;
}
else
*pc = 0;
}
Why clang doesn't ?
--
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