Re: [Zope3-dev] Bytes versus ASCII

2006-02-03 Thread Egon Frerich
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Gary Poster schrieb am 27.01.2006 21:40: On Jan 27, 2006, at 5:16 AM, Christian Theune wrote: Hi, (this is about zope.schema) I assumed that the fields Bytes and ASCII have some distinction. The ASCII field explicitly checks for every

[Zope3-dev] Bytes versus ASCII

2006-01-27 Thread Christian Theune
Hi, (this is about zope.schema) I assumed that the fields Bytes and ASCII have some distinction. The ASCII field explicitly checks for every character to have an ordinal value lower than 127. Bytes however does a cast in fromUnicode(u) that does str(u). This will break if there are non-ascii

Re: [Zope3-dev] Bytes versus ASCII

2006-01-27 Thread Gary Poster
On Jan 27, 2006, at 5:16 AM, Christian Theune wrote: Hi, (this is about zope.schema) I assumed that the fields Bytes and ASCII have some distinction. The ASCII field explicitly checks for every character to have an ordinal value lower than 127. Bytes however does a cast in fromUnicode(u)