faqts : Computers : Programming : Languages : Python : Common Problems

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

3 of 3 people (100%) answered Yes
Recently 1 of 1 people (100%) answered Yes

Entry

Is it possible to get the reference count of a PyObject* object?

Aug 27th, 2000 22:07
unknown unknown, Just van Rossum


sys.getrefcount(object)
Note that this always returns one more than the actual value, as
there's always an additional ref when inside sys.getrefcount().