On 8/01/20 9:22 am, hrfu...@gmail.com wrote:
how can I know if a PyObject_Call(...) or PyObject_GetAttr(...) returns a new ref or a borrowed ref? I read online ( Python 3 ) that they are returning new references. But does everyone comply with it?
They always return new references. Yes, everyone complies with it. (If they don't, their code crashes the interpreter and they get a visit from the Spanish Inquisition.) -- Greg _______________________________________________ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to python-ideas-le...@python.org https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/python-ideas@python.org/message/7VTFSBGKSBB7PEIZMK3G4KIUECIKHMZR/ Code of Conduct: http://python.org/psf/codeofconduct/