[Python-3000] iostack and Oh Oh
Greg Ewing
greg.ewing at canterbury.ac.nz
Sat Dec 2 03:24:23 CET 2006
tomer filiba wrote:
> when a proxy is created for an object in another
> process, you can only set __class__ to a *proxy* to the remote type...
> so isinstance fails.
But the class being passed to isinstance() can only be
a proxy to the remote class as well, so as long as it's
the same proxy that the overridden __class__ returns,
it should work, shouldn't it?
IOW,
in process A:
x.__class__ is X
so
isinstance(x, X) == True
in process B:
x_proxy.__class__ is X_proxy
so
isinstance(x_proxy, X_proxy) == True
--
Greg
More information about the Python-3000
mailing list