Message263956
According to PEP3123, all accesses to ob_refcnt and ob_type MUST cast the object pointer to PyObject* (unless the pointer is already known to have that type), and SHOULD use the respective accessor macros.
I find that there are still some macros in Python use (obj)->ob_type. Though right now they may not impose any error, but as macros, they may be used with arguments not of type PyObject* later and introduce errors. So I think change them to use Py_TYPE is not a bad idea. |
|
Date |
User |
Action |
Args |
2016-04-22 04:54:50 | xiang.zhang | set | recipients:
+ xiang.zhang, serhiy.storchaka |
2016-04-22 04:54:50 | xiang.zhang | set | messageid: <1461300890.73.0.522492647874.issue26824@psf.upfronthosting.co.za> |
2016-04-22 04:54:50 | xiang.zhang | link | issue26824 messages |
2016-04-22 04:54:50 | xiang.zhang | create | |
|