translating foreign data
Peter J. Holzer
peter.j..holzer at 1
Sat Jun 23 15:28:30 EDT 2018
From: "Peter J. Holzer" <hjp-python at hjp.at>
--drblskvcly73v23o
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
On 2018-06-23 08:12:52 -0400, Richard Damon wrote:
> On 6/23/18 7:46 AM, Steven D'Aprano wrote:
> > On Sat, 23 Jun 2018 06:26:22 -0400, Richard Damon wrote:
> >> If you know the Locale, then you do know what the decimal separator is,
> >> as that is part of what a locale defines.
> > A locale defines a set of common cultural conventions. It doesn't manda=
te=20
> > the actual conventions in use in any specific document.
> >
> > If I'm in Australia, using the en-AU locale, nevertheless I can generat=
e=20
> > a file using , as a decimal separator. Try and stop me :-)
> yes, you can MIS-use the en-AU locale and write 1,000 to mean the number
> One, just as you can misuse the language and write cat when you mean a
> member of the Canine group, but then the misinterpretation is on the
> creator of the document, not on the program that was told how the
> document is to be read.
How would he mis-use the en-AU locale to write 1 as "1,000"? I think to do that
he would simply NOT use the locale.
I think there are very good reasons to ignore the locale for specific purposes.
For example, a Python interpreter should not use the locale when parsing
Python, and a program producing Python should also ignore the locale.
You two also seem to be writing about different things when you write "THE
locale". Steven seems to mean the global settings a user has chosen, you seem
to mean the specidic settings appropriate for parsing a specific file.
hp
--=20
_ | Peter J. Holzer | we build much bigger, better disasters now
|_|_) | | because we have much more sophisticated
| | | hjp at hjp.at | management tools.
__/ | http://www.hjp.at/ | -- Ross Anderson <https://www.edge.org/>
--drblskvcly73v23o
Content-Type: application/pgp-signature; name="signature.asc"
-----BEGIN PGP SIGNATURE-----
iQIzBAABCAAdFiEETtJbRjyPwVTYGJ5k8g5IURL+KF0FAlsuPOoACgkQ8g5IURL+
KF3nWw//T34BviAcOezJAU59Fkp7i6gcaTJ4meYOkvvXaipB3QQGIVKZck1T/6VE
UcNJQipftT1/g3Uf4C9VRlrGwe2vq7QbeP220jBEECztmoqCBzpOgaVxOlpiP0gD
YiPDdk69KZYzjtt6kTO6kwAVLRereyYh4kPeq2zrpSe0tmx53jg9RrmztQz9SFtk
kU8klPFb1jzmgG8RLqrcB9FuUrBzfDxEXSsbHEqVqckAT9rYMLUtuqQPPZbi2zkC
ncXXVvBVA061CcYwvnIxfp8jWvAlXwKwC1mv7DFkOtSgnoo85STmWcGryybJsTID
cgCY90hnWfWM6rqLCS9eoeMMYOUItsxu0/uOAhsRMipt4lMI2Ebzhk5Udv87RFme
CmJEcSEHwYD4iB2Zw2BE8DksSyfciNbuWYS7GHiMz/fiO25upVikCoNZEPk1Xu/C
6wJ+H6fsSv4GGdQls25ykyyt73b+OXGvbIr8hp3Mcup/Fn5P0BCc2vZehDxNaC4p
alzqhRLfql2Hhr1TyPdapuxixBuD55PeRYOpKrpZmeQ0/O2m3Zube2Z3CrhPmQvH
JNdI5suWRyV52QVvDQXV/3bUVywehe8C/kmPtWl0FeDaZPjcO/yHOgQK2abGYfAs
t9vAMldEpQmBixh/hOqeGs5y9xLwQgf7liyvAV1ak2gIr9ntgdI=
=XB3R
-----END PGP SIGNATURE-----
--drblskvcly73v23o--
--- BBBS/Li6 v4.10 Toy-3
* Origin: Prism bbs (1:261/38)
More information about the Python-list
mailing list