On Wed, 12 Oct 2005 10:56:44 +0200, =?ISO-8859-1?Q?=22Martin_v=2E_L=F6wis=22?= <[EMAIL PROTECTED]> wrote:
>Mike Meyer wrote: >> Out of random curiosity, is there a PEP/thread/? that explains why >> Python symbols are restricted to 7-bit ascii? > >No PEP yet; I meant to write one for several years now. > >The principles would be >- sources must use encoding declarations >- valid identifiers would follow the Unicode consortium guidelines, > in particular: identifiers would be normalized in NFKC (I think), > adjusted in the ASCII range for backward compatibility (i.e. > not introducing any additional ASCII characters as legal identifier > characters) >- __dict__ will contain Unicode keys >- all objects should support Unicode getattr/setattr (potentially > raising AttributeError, of course) >- open issue: what to do on the C API (perhaps nothing, perhaps > allowing UTF-8) Perhaps string equivalence in keys will be treated like numeric equivalence? I.e., a key/name representation is established by the initial key/name binding, but values can be retrieved by "equivalent" key/names with different representations like unicode vs ascii or latin-1 etc.? Regards, Bengt Richter -- http://mail.python.org/mailman/listinfo/python-list