how to avoid -Wconversion warning about float to integer conversion

Martin Ettl ettl.martin@gmx.de
Sun Sep 27 13:23:00 GMT 2009


Hello,

recently i have actived the -Wconverion flag of g++-4.4.1 on my Ubuntu linux system. It brought up a warning (http://trac.wxwidgets.org/ticket/11252). Now my question: g++ warns about, that it may change the value. How to make do it correctly? Is there a function to check a float number fits into an integer?

Best regards

Martin

-- 
Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3.5 -
sicherer, schneller und einfacher! http://portal.gmx.net/de/go/chbrowser



More information about the Gcc-help mailing list