Version française
Home     About     Download     Resources     Contact us    
Browse thread
Strange behaviour of string_of_float
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: David Allsopp <dra-news@m...>
Subject: RE: [Caml-list] Strange behaviour of string_of_float
> > All that said, the values given by
> > string_of_float cannot always be fed back to float_of_string anyway
> > (e.g. float_of_string (string_of_float nan))
>
> euh, why do you say that ? it does :
>
>   # float_of_string (string_of_float nan) ;;
>   - : float = nan

Because:


        Objective Caml version 3.09.3

# float_of_string (string_of_float nan);;
Exception: Failure "float_of_string".


but this is clearly fixed in 3.10!


David