Mercurial > public > mercurial-scm > hg
comparison mercurial/revset.py @ 14900:fc3d6f300d7d
revset: allow bypassing alias expansion
For internal usage of revset queries, we don't want aliases breaking things.
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Thu, 21 Jul 2011 14:04:57 -0500 |
parents | f96c354493d7 |
children | a773119f30ba |
comparison
equal
deleted
inserted
replaced
14899:6d1d0b9c4ecc | 14900:fc3d6f300d7d |
---|---|
1017 if not spec: | 1017 if not spec: |
1018 raise error.ParseError(_("empty query")) | 1018 raise error.ParseError(_("empty query")) |
1019 tree, pos = parse(spec) | 1019 tree, pos = parse(spec) |
1020 if (pos != len(spec)): | 1020 if (pos != len(spec)): |
1021 raise error.ParseError(_("invalid token"), pos) | 1021 raise error.ParseError(_("invalid token"), pos) |
1022 tree = findaliases(ui, tree) | 1022 if ui: |
1023 tree = findaliases(ui, tree) | |
1023 weight, tree = optimize(tree, True) | 1024 weight, tree = optimize(tree, True) |
1024 def mfunc(repo, subset): | 1025 def mfunc(repo, subset): |
1025 return getset(repo, subset, tree) | 1026 return getset(repo, subset, tree) |
1026 return mfunc | 1027 return mfunc |
1027 | 1028 |