Martin v. Löwis <mar...@v.loewis.de> added the comment:

In a sense, *all* objects are instances of new-style classes in 2.x, including 
instances of old-style classes (which are instances of the InstanceType type, 
which is a type, and hence a new-style class).

You may want to look at the __flags__ property of the type object. If it is a 
heap type, there is a good chance that it was created through a class 
statement. Alternatively, you can look at the type's __module__, and find out 
whether the module is a Python module.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue8206>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to