# HG changeset patch # User Mads Kiilerich # Date 2014-02-24 21:42:13 # Node ID 24e0661e6c2e2a5a08a34dfc6f183fd00a9e05d4 # Parent 86cefb15e7b5cbb4c6d99a80942d922e998e1a38 parsers: remove unreachable and invalid code in index_ancestors The function normally returns a list. Returning a single element instead of a list with one element would be weird. diff --git a/mercurial/parsers.c b/mercurial/parsers.c --- a/mercurial/parsers.c +++ b/mercurial/parsers.c @@ -1529,10 +1529,6 @@ static PyObject *index_ancestors(indexOb ret = gca; Py_INCREF(gca); } - else if (PyList_GET_SIZE(gca) == 1) { - ret = PyList_GET_ITEM(gca, 0); - Py_INCREF(ret); - } else ret = find_deepest(self, gca); done: