D4039: [RFC] shortest: cache disambiguation revset

Yuya Nishihara yuya at tcha.org
Fri Aug 3 23:06:11 EDT 2018


>   This doesn't seem like the right way to cache it. Suggestions?

Suppose the cache exists mainly for templating, templatefuncs.shortest()
can pass in a cached revset to resolvehexnodeidprefix(), and we don't have
to take care of cache invalidation.

If we want to cache a prefix tree, maybe it could be turned into a "resolver"
object which the templater creates at the first shortest() call.


More information about the Mercurial-devel mailing list