On Fri, Dec 2, 2011 at 7:54 PM, Steven D'Aprano <steve+comp.lang.pyt...@pearwood.info> wrote: > Dude, it was deliberately obfuscated code. I even named the function > "obfuscated_prefixes". I thought that would have been a hint <wink> > > It's kinda scary that of all the sins against readability committed in my > function, including isinstance(type(c), type(type)) which I was > particularly proud of, the only criticism you came up with was that > chr(45) is hard to read. I'm impressed <grins like a mad thing>
Heh! I know it was obfuscated, and that's why I didn't bother mentioning the obvious. > And besides, given how rare such byte-manipulations on ASCII characters > are in Python, it would be a shame to lose the ability to use '' and "" > for strings just to avoid calling ord and chr functions. Agreed. That flexibility is a _huge_ advantage. Definitely not worth changing anything. ChrisA -- http://mail.python.org/mailman/listinfo/python-list