summaryrefslogtreecommitdiffstats
path: root/Objects
diff options
context:
space:
mode:
authorMark Dickinson <dickinsm@gmail.com>2010-05-22 12:02:35 (GMT)
committerMark Dickinson <dickinsm@gmail.com>2010-05-22 12:02:35 (GMT)
commitfff532bef328f78ac149123845b1962d9ca5ba59 (patch)
tree404f5b45582b2265e4e68b6df7bf184892fdf99f /Objects
parent3fed0870a6fec72665068e09200c674b574dabdb (diff)
downloadcpython-fff532bef328f78ac149123845b1962d9ca5ba59.zip
cpython-fff532bef328f78ac149123845b1962d9ca5ba59.tar.gz
cpython-fff532bef328f78ac149123845b1962d9ca5ba59.tar.bz2
Issue #8749: remove unused code in Objects/object.c. Thanks Yaniv Aknin.
Diffstat (limited to 'Objects')
-rw-r--r--Objects/object.c24
1 files changed, 0 insertions, 24 deletions
diff --git a/Objects/object.c b/Objects/object.c
index 7907a8e..0802348 100644
--- a/Objects/object.c
+++ b/Objects/object.c
@@ -950,31 +950,7 @@ PyObject_GenericGetAttr(PyObject *obj, PyObject *name)
goto done;
}
-#if 0 /* XXX this is not quite _PyType_Lookup anymore */
- /* Inline _PyType_Lookup */
- {
- Py_ssize_t i, n;
- PyObject *mro, *base, *dict;
-
- /* Look in tp_dict of types in MRO */
- mro = tp->tp_mro;
- assert(mro != NULL);
- assert(PyTuple_Check(mro));
- n = PyTuple_GET_SIZE(mro);
- for (i = 0; i < n; i++) {
- base = PyTuple_GET_ITEM(mro, i);
- assert(PyType_Check(base));
- dict = ((PyTypeObject *)base)->tp_dict;
- assert(dict && PyDict_Check(dict));
- descr = PyDict_GetItem(dict, name);
- if (descr != NULL)
- break;
- }
- }
-#else
descr = _PyType_Lookup(tp, name);
-#endif
-
Py_XINCREF(descr);
f = NULL;