This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

can this happen?


Dear gcc,

is the following scenario possible (rounding errors, . . .) or must it
be a bug?


double a, b;

some code

if ( a<b){
  fprintf("%g", a-b);
}


the output is "0"
if either a or b is printed before the if-statement,  there is no output
at all.

gcc version 2.95.1
compiling optionts: o1

yours,
erich janka


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]