errors: raise InputError on recursive template definition
Differential Revision: https://phab.mercurial-scm.org/D9602
--- a/mercurial/templater.py Mon Nov 23 16:39:53 2020 -0800
+++ b/mercurial/templater.py Thu Nov 12 10:41:03 2020 -0800
@@ -451,7 +451,7 @@
def _runrecursivesymbol(context, mapping, key):
- raise error.Abort(_(b"recursive reference '%s' in template") % key)
+ raise error.InputError(_(b"recursive reference '%s' in template") % key)
def buildtemplate(exp, context):
--- a/tests/test-template-basic.t Mon Nov 23 16:39:53 2020 -0800
+++ b/tests/test-template-basic.t Thu Nov 12 10:41:03 2020 -0800
@@ -265,7 +265,7 @@
> EOF
$ hg log --style ./issue4758
abort: recursive reference 'changeset' in template
- [255]
+ [10]
not a recursion if a keyword of the same name exists: