John Nagle wrote:

>     "weakref.proxy()" probably should work that way.
> Weakref proxies are supposed to be transparent, but they're not
> quite transparent enough.

Submit a patch to SourceForge. Please don't use tabs in email/usenet
postings - use 4-space indents. "return" is not a function, and
comparisons with "None" should nearly always use "is".

I've also changed backref() to use isinstance(obj, tuple) (available in
Python 2.2 and later):

    def backref(p):
        if p is None:
            return None

        if isinstance(p, (weakref.ProxyType,
weakref.CallableProxyType)):
            return p

        return weakref.proxy(p)

Tim Delaney
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to