GCC issues warnings like division by zero or right shift count = width of
type even though the corresponding code will never be executed (under a
condition that is always false); it shouldn't do this, at least by default. For
instance:
int tst (void)
{
int x;
x = 0 ? 1 / 0 : 0;
return x;
This is a dup of a much older bug which I cannot find right now.
On Jul 6, 2010, at 8:10 AM, vincent at vinc17 dot org gcc-bugzi...@gcc.gnu.org
wrote:
GCC issues warnings like division by zero or right shift count =
width of
type even though the corresponding code will never be executed