Mercurial > public > mercurial-scm > hg
diff mercurial/cext/revlog.h @ 40861:b12700dd261f
revlog: add public CPython function to get parent revisions
Since this is a public function, it validates the input revision, and supports
nullrev. index_get_parents_checked() will be replaced by this function.
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Sun, 02 Dec 2018 22:10:37 +0900 |
parents | 18a8def6e1b5 |
children | 9db11679f8ac |
line wrap: on
line diff
--- a/mercurial/cext/revlog.h Sun Dec 02 21:41:24 2018 +0900 +++ b/mercurial/cext/revlog.h Sun Dec 02 22:10:37 2018 +0900 @@ -12,4 +12,8 @@ extern PyTypeObject HgRevlogIndex_Type; +#define HgRevlogIndex_Check(op) PyObject_TypeCheck(op, &HgRevlogIndex_Type) + +int HgRevlogIndex_GetParents(PyObject *op, int rev, int *ps); + #endif /* _HG_REVLOG_H_ */