[Python-Dev] Re: Multibyte repr()

Tamito KAJIYAMA kajiyama@grad.sccs.chukyo-u.ac.jp
Sat, 12 Oct 2002 16:24:19 +0900


Hi,

I know it's too late to post this, but I'd like to express my
opinion on locale-dependent repr() from a CJKV user's viewpoint.

Guido <guido@python.org> writes:
|
| I don't think this particular issue (pickling) is a problem.  But I
| *do* continue to worry that making repr() depend on the locale may be
| a bigger problem than what it attempts to solve.

I think locale-dependent repr() is a bad idea.

The most important (IMHO) aspect of repr() is that returned
values of repr() can be used as fragments of Python programs.
If repr() were locale-dependent, the returned values could not
be used as fragments in some cases.  In Japanese applications,
Shift_JIS string literals would be a major problem in this
sense.

I think one of the virtues of Python is that Python has no
language feature that is (automagically) affected by locale
settings.  Applications with locale-specific features would be
useful, but I wish Python be as locale-independent as possible.

Regards,

-- 
KAJIYAMA, Tamito <kajiyama@grad.sccs.chukyo-u.ac.jp>