Mercurial > hg-stable
diff tests/test-glog.t @ 25765:5e1b0739611c
revset: use integer representation of wdir() in revset
This is the simplest way to handle wdir() revision in revset. None didn't
work well because revset heavily depends on integer operations such as min(),
max(), sorted(), x:y, etc.
One downside is that we cannot do "wctx.rev() in set" because wctx.rev() is
still None. We could wrap the result set by wdirproxyset that translates None
to wdirrev, but it seems overengineered at this point.
result = getset(repo, subset, tree)
if 'wdir' in funcsused(tree):
result = wdirproxyset(result)
Test cases need the '(all() + wdir()) &' hack because we have yet to fix the
bootstrapping issue of null and wdir.
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Mon, 16 Mar 2015 16:17:06 +0900 |
parents | c76e8d14383a |
children | 8117e2cd959e |
line wrap: on
line diff