bpo-39573: Use Py_TYPE() macro in Python and Include directories (GH-18391)

Replace direct access to PyObject.ob_type with Py_TYPE().
12 files changed