On 3/3/07, Bob Ippolito <[EMAIL PROTECTED]> wrote: > When Erlang is printing the "repr" of a list or binary term to the > shell it first checks to see if every item is printable ASCII integer. > If so, then it prints as an ASCII string. Otherwise, it prints as a > list of decimal integers. It doesn't work out well in these kinds of > situations. If it was printed out as ASCII with hex escapes then it > would make a lot more sense at a glance.
Perhaps it would be best to make one format the default, but provide a convenience method on the bytes type for the other format? repr(b) -> bytes("spam spam spam")' b.hex() -> "7370616d 20737061 6d207370 616d" -- Daniel Stutzbach, Ph.D. President, Stutzbach Enterprises LLC _______________________________________________ Python-3000 mailing list Python-3000@python.org http://mail.python.org/mailman/listinfo/python-3000 Unsubscribe: http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com