changeset 24219:282c0d8c1880

revset: use UnknownIdentifier where appropriate
author Augie Fackler <augie@google.com>
date Mon, 26 Jan 2015 14:32:30 -0500
parents cecaec0e8719
children fe195d41f7d2
files mercurial/revset.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/revset.py	Mon Jan 26 14:31:48 2015 -0500
+++ b/mercurial/revset.py	Mon Jan 26 14:32:30 2015 -0500
@@ -368,7 +368,7 @@
 def func(repo, subset, a, b):
     if a[0] == 'symbol' and a[1] in symbols:
         return symbols[a[1]](repo, subset, b)
-    raise error.ParseError(_("not a function: %s") % a[1])
+    raise error.UnknownIdentifier(a[1], symbols.keys())
 
 # functions
 
@@ -2151,7 +2151,7 @@
     if isinstance(tree, tuple):
         arg = _getaliasarg(tree)
         if arg is not None and (not known or arg not in known):
-            raise error.ParseError(_("not a function: %s") % '_aliasarg')
+            raise error.UnknownIdentifier('_aliasarg', [])
         for t in tree:
             _checkaliasarg(t, known)