Benjamin Peterson added the comment: You could use the Py_SAFE_DOWNCAST macro everywhere. ---------- _______________________________________ Python tracker <report at bugs.python.org> <http://bugs.python.org/issue19617> _______________________________________