[Python-Dev] Re: Be Honest about LC_NUMERIC [REPOST] (original) (raw)
Martin v. Löwis martin at v.loewis.de
Mon Sep 1 22:36:59 EDT 2003
- Previous message: [Python-Dev] Re: Be Honest about LC_NUMERIC [REPOST]
- Next message: [Python-Dev] Re: Be Honest about LC_NUMERIC [REPOST]
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Guido van Rossum <guido at python.org> writes:
Here's yet another idea (which probably has flaws as well): instead of substituting the locale's decimal separator, rewrite strings like "3.14" as "314e-2" and rewrite strings like "3.14e5" as "314e3", then pass to strtod(), which assigns the same meaning to such strings in all locales.
Unfortunately, that doesn't work for sprintf, for which you still need to replace the radixchar.
Regards, Martin
- Previous message: [Python-Dev] Re: Be Honest about LC_NUMERIC [REPOST]
- Next message: [Python-Dev] Re: Be Honest about LC_NUMERIC [REPOST]
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]