Re: [Python-Dev] Tightening up the specification for locals()

2013-05-13 Thread Fábio Santos
> Like it or not, people rely on this behavior. I don't think CPython > (or PyPy) can actually afford to change it. If so, documenting it > sounds like a better idea than leaving it undocumented only known to > the "inner shrine" > +1. I am relying on this.

Re: [Python-Dev] Why can't I encode/decode base64 without importing a module?

2013-04-22 Thread Fábio Santos
Using decode() and encode() would break that predictability. But someone suggested the use of transform() and untransform() instead. That would clarify that the transformation is bytes > bytes and Unicode string > Unicode string. On 23 Apr 2013 05:50, "Lennart Regebro" wrote: > On Tue, Apr 23, 20

Re: [Python-Dev] PEP 435 -- Adding an Enum type to the Python standard library

2013-04-12 Thread Fábio Santos
d to find bugs. On the other hand, simply checking in `__cmp__` what Enum both values belong to (since they do have a `enum` attribute) should allow us to avoid cross-comparing instead of just raising a TypeError. It's not very intuitive behavior IMHO. Just my 2 cent