##// END OF EJS Templates
revset: make _parsealiasdecl() simply return the original parsed tree...
Yuya Nishihara -
r28708:ab06b5ef default
parent child Browse files
Show More
@@ -2293,7 +2293,7 b' def _parsealiasdecl(decl):'
2293 name = tree[1]
2293 name = tree[1]
2294 if name.startswith('$'):
2294 if name.startswith('$'):
2295 return (decl, None, None, _("'$' not for alias arguments"))
2295 return (decl, None, None, _("'$' not for alias arguments"))
2296 return (name, ('symbol', name), None, None)
2296 return (name, tree, None, None)
2297
2297
2298 if tree[0] == 'func' and tree[1][0] == 'symbol':
2298 if tree[0] == 'func' and tree[1][0] == 'symbol':
2299 # "name(arg, ....) = ...." style
2299 # "name(arg, ....) = ...." style
@@ -2308,7 +2308,7 b' def _parsealiasdecl(decl):'
2308 if len(args) != len(set(args)):
2308 if len(args) != len(set(args)):
2309 return (name, None, None,
2309 return (name, None, None,
2310 _("argument names collide with each other"))
2310 _("argument names collide with each other"))
2311 return (name, ('func', ('symbol', name)), args, None)
2311 return (name, tree[:2], args, None)
2312
2312
2313 return (decl, None, None, _("invalid format"))
2313 return (decl, None, None, _("invalid format"))
2314 except error.ParseError as inst:
2314 except error.ParseError as inst:
General Comments 0
You need to be logged in to leave comments. Login now