Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/parser.py @ 28720:639e0f1e8ffa
parser: move parsererrordetail() function from revset module
This will be used by common alias functions introduced by future patches.
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Mon, 29 Feb 2016 17:02:56 +0900 |
parents | 87c9c562c37a |
children | 475dad3432fd |
comparison
equal
deleted
inserted
replaced
28719:dd2cf90a3731 | 28720:639e0f1e8ffa |
---|---|
218 simplified.append(simplifyinfixops(r, targetnodes)) | 218 simplified.append(simplifyinfixops(r, targetnodes)) |
219 x = l | 219 x = l |
220 simplified.append(simplifyinfixops(x, targetnodes)) | 220 simplified.append(simplifyinfixops(x, targetnodes)) |
221 simplified.append(op) | 221 simplified.append(op) |
222 return tuple(reversed(simplified)) | 222 return tuple(reversed(simplified)) |
223 | |
224 def parseerrordetail(inst): | |
225 """Compose error message from specified ParseError object | |
226 """ | |
227 if len(inst.args) > 1: | |
228 return _('at %s: %s') % (inst.args[1], inst.args[0]) | |
229 else: | |
230 return inst.args[0] |