https://bugs.llvm.org/show_bug.cgi?id=37305
Bug ID: 37305
Summary: Clang warning message on FP to integer implicit
conversion is inconsistent with its behavior.
Product: clang
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: C++
Assignee: unassignedclangb...@nondot.org
Reporter: erich.ke...@intel.com
CC: dgre...@apple.com, llvm-bugs@lists.llvm.org
Given the following reproducer:
short s() {
return 32768.0;
}
char c() {
return 128.0;
}
We get the warnings:
warning: implicit conversion from 'double' to 'short' changes value from 32768
to 32767
and
warning: implicit conversion from 'double' to 'char' changes value from 128 to
127
HOWEVER, the LLVM-IR emitted actually replaces the 'ret' with ret i16 undef and
ret i8 undef respectively.
We should make this consistent, either by altering the commit message or by
changing the behavior.
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs