Browse thread
[Caml-list] string_of_float -> float_of_string locale dependency bug
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Xavier Leroy <xavier.leroy@i...> |
| Subject: | Re: [Caml-list] string_of_float -> float_of_string locale dependency bug |
> Another approach: write own strtod function which doesn't depend on > the LC_NUMERIC locale. Of course, having our own string <-> float conversions would work around this issue and other issues as well, such as the inability of the C library functions to print a float *exactly* (i.e. with just enough decimals that it reads back to the very same float). This is no small undertaking, however, and one has a feeling of reinventing the wheel. The ANSI C standard library is quite small to begin with, but the addition of locales managed to render it even less useful... - Xavier Leroy ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners