On Wed, Feb 29, 2012 at 08:59:52AM +0000, Michael Haberler wrote:
> +    if hasattr(interpreter,'this'):
> +        if self != interpreter.this:
> +            print "__init__: self != this"

I *think* that your intent here is to check for object identity.  If so,
you want to write
    if self.interpreter is not self.this: ...

However, the test probably checks approximately what you intend, because
"If no __cmp__(), __eq__() or __ne__() operation is defined, class
instances are compared by object identity (“address”)."
-- http://docs.python.org/reference/datamodel.html#object.__cmp__

Jeff

------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing 
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
Emc-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-developers

Reply via email to