Re: python 2.3.4 for windows: float("NaN") throws exception

2005-01-13 Thread John Roth
<[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] Hi my python 2.3.4 for windows refuse to execute line float("NaN"). It says: float("NaN") Traceback (most recent call last): File "", line 1, in ? ValueError: invalid literal for float(): NaN The same line works as expected on Linux and S

Re: python 2.3.4 for windows: float("NaN") throws exception

2005-01-13 Thread Tim Peters
[EMAIL PROTECTED] > C99 and Fortran 2003 have IEEE arithmetic. Not that simple (e.g., C99 doesn't *require* it; but it has a pile of specified IEEE behaviors a conforming C99 compiler can choose to support (or not), along with a preprocessor symbol those that do so choose can #define to advertise

Re: python 2.3.4 for windows: float("NaN") throws exception

2005-01-13 Thread beliavsky
Tim Peters wrote: >Neither -- all Python behavior in the presence of float NaNs, infinities, or signed zeroes is a platform-dependent accident. C99 and Fortran 2003 have IEEE arithmetic. If CPython could be compiled with a C99 compiler, would it also have IEEE arithmetic? Do Python number-cruncher

Re: python 2.3.4 for windows: float("NaN") throws exception

2005-01-13 Thread Peter Hansen
[EMAIL PROTECTED] wrote: my python 2.3.4 for windows refuse to execute line float("NaN"). It says: float("NaN") Traceback (most recent call last): File "", line 1, in ? ValueError: invalid literal for float(): NaN The same line works as expected on Linux and Solaris with python 2.3.4. Could anybody

Re: python 2.3.4 for windows: float("NaN") throws exception

2005-01-13 Thread Fredrik Lundh
<[EMAIL PROTECTED]> wrote: > my python 2.3.4 for windows refuse to execute line float("NaN"). It > says: > float("NaN") > Traceback (most recent call last): > File "", line 1, in ? > ValueError: invalid literal for float(): NaN > > The same line works as expected on Linux and Solaris with pyt

Re: python 2.3.4 for windows: float("NaN") throws exception

2005-01-13 Thread Tim Peters
[EMAIL PROTECTED] > my python 2.3.4 for windows refuse to execute line float("NaN"). It > says: > > >>> float("NaN") > Traceback (most recent call last): > File "", line 1, in ? > ValueError: invalid literal for float(): NaN > > The same line works as expected on Linux and Solaris with python 2.3.