revlog: make chainbase cache its result for the correct revision
Previously, as 'rev' was our iterator, we were always caching the chain base
for the second revision of the chain, or for the base itself.
#require docutils gettext $ $TESTDIR/check-gendoc el checking for parse errors