templater: introduce wrapper for smartset (API)
I want to add a template function which takes a revset as an argument: {somefunc(..., revset(...))} ^^^^^^^^^^^ evaluates to a revslist This wrapper will provide a method to get an underlying smartset. It should also be good for performance since count(revset(...)) will no longer have to fully consume the smartset for example, but that isn't the point of this change.
Showing
- mercurial/templatefuncs.py 1 addition, 1 deletionmercurial/templatefuncs.py
- mercurial/templatekw.py 0 additions, 18 deletionsmercurial/templatekw.py
- mercurial/templater.py 3 additions, 0 deletionsmercurial/templater.py
- mercurial/templateutil.py 69 additions, 0 deletionsmercurial/templateutil.py
- tests/test-template-functions.t 48 additions, 0 deletionstests/test-template-functions.t
Loading
Please register or sign in to comment