On Thu, Oct 16, 2008 at 08:52:06PM +0200, Benjamin Wolsey wrote:
> 
> > This solution seems acceptable to me, but I'm curious if anyone can
> > shed some light on the floating point conversion:
> > 
> > return static_cast<boost::int32_t>(static_cast<boost::uint32_t>(a * 20));
> > 
> > used in PIXELS_TO_TWIPS.  Is there a compiler flag or something that
> > allows negative floating point numbers to be converted to a non-zero
> > unsigned int that I'm missing for my cross compile?
> > 
> 
> It's undefined behaviour, so there's nothing you can do to be sure on
> any platform. I think we should be using the safe conversion all the
> time.

Is this what zou was talking about too ?

+1 for going the safe way always (never mind if it's slower)

--strk;


_______________________________________________
Gnash-dev mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/gnash-dev

Reply via email to