Re: SVG12: conversion to float vs NaN

* Nandini Ramani wrote:
>    Thank you for your comments regarding conversion to float vs NaN [1].
>
>As per the IEEE definition, NaN is returned as a result of an arithmetic
>operation,
>like 0/0. It is not appropriate to use it for conversions. So, in the
>case of getFloatTrait, we have a consistent approach to throw an
>exception when it is called for a trait that cannot be converted to a
>float type.

Okay, I shall rephrase my issue then: the current draft does not seem to
specify when a trait value can be converted to a "float" and does seem
to specify an algorithm to be used for this conversion. A na�ve viewer
implementation might keep such values internally as strings and use some
string to number conversion facilities provided by the platform to make
such a conversion and might fail to check for errors; a possible result
of this are viewers that return special values like NaN to unexpecting
DOM applications; the draft should work against na�ve implementations by
clearly defining this.
-- 
Bj�rn H�hrmann � mailto:bjoern@hoehrmann.de � http://bjoern.hoehrmann.de
Weinh. Str. 22 � Telefon: +49(0)621/4309674 � http://www.bjoernsworld.de
68309 Mannheim � PGP Pub. KeyID: 0xA4357E78 � http://www.websitedev.de/ 

Received on Tuesday, 27 December 2005 22:01:35 UTC