Mercurial > hg
comparison mercurial/commands.py @ 13665:e798e430c5e5
revset: report a parse error if a revset is not parsed completely (issue2654)
author | Bernhard Leiner <bleiner@gmail.com> |
---|---|
date | Wed, 16 Mar 2011 23:09:14 +0100 |
parents | d16c99f16f00 |
children | 4f5ed2bd1724 |
comparison
equal
deleted
inserted
replaced
13664:53db4e2026ab | 13665:e798e430c5e5 |
---|---|
1235 v.encode('string-escape'))) | 1235 v.encode('string-escape'))) |
1236 | 1236 |
1237 def debugrevspec(ui, repo, expr): | 1237 def debugrevspec(ui, repo, expr): |
1238 '''parse and apply a revision specification''' | 1238 '''parse and apply a revision specification''' |
1239 if ui.verbose: | 1239 if ui.verbose: |
1240 tree = revset.parse(expr) | 1240 tree = revset.parse(expr)[0] |
1241 ui.note(tree, "\n") | 1241 ui.note(tree, "\n") |
1242 func = revset.match(expr) | 1242 func = revset.match(expr) |
1243 for c in func(repo, range(len(repo))): | 1243 for c in func(repo, range(len(repo))): |
1244 ui.write("%s\n" % c) | 1244 ui.write("%s\n" % c) |
1245 | 1245 |