Forum : 8051
Original Post
| Post Information | Post |
|---|---|
|
July 17, 2008 - 9:04pm
|
When converting a negative floating point number to integer or long integer, // Test of float -> int conversion
// compile with BCD floating point
#include
int Itest;
float Ftest;
// Just to fool the optimiser that it's not a constant
float dummy( float x){ return x;}
main(){
Ftest = dummy(-3.5);
// With BCD floating point this loses its sign and gets +3
// With IEEE floating point it gets -3
Itest = Ftest;
}
|
Hi Puposet
We have verified and fixed this problem.
Thank you for reporting us this point.
The fix will be available on the next release of RKit51.
If you immediately need a fix for your project please send me an email at
Best regards,
Matloub