Show More
@@ -600,6 +600,7 b' def formatspec(expr, *args):' | |||||
600 | return _quote(node.hex(arg)) |
|
600 | return _quote(node.hex(arg)) | |
601 | elif c == 'b': |
|
601 | elif c == 'b': | |
602 | return _quote(arg.branch()) |
|
602 | return _quote(arg.branch()) | |
|
603 | raise error.ParseError(_('unexpected revspec format character %s') % c) | |||
603 |
|
604 | |||
604 | def listexp(s, t): |
|
605 | def listexp(s, t): | |
605 | l = len(s) |
|
606 | l = len(s) | |
@@ -633,16 +634,13 b' def formatspec(expr, *args):' | |||||
633 | d = expr[pos] |
|
634 | d = expr[pos] | |
634 | if d == '%': |
|
635 | if d == '%': | |
635 | ret.append(d) |
|
636 | ret.append(d) | |
636 | elif d in 'dsnbr': |
|
|||
637 | ret.append(argtype(d, next(argiter))) |
|
|||
638 | elif d == 'l': |
|
637 | elif d == 'l': | |
639 | # a list of some type |
|
638 | # a list of some type | |
640 | pos += 1 |
|
639 | pos += 1 | |
641 | d = expr[pos] |
|
640 | d = expr[pos] | |
642 | ret.append(listexp(list(next(argiter)), d)) |
|
641 | ret.append(listexp(list(next(argiter)), d)) | |
643 | else: |
|
642 | else: | |
644 | raise error.ParseError(_('unexpected revspec format character %s') |
|
643 | ret.append(argtype(d, next(argiter))) | |
645 | % d) |
|
|||
646 | pos += 1 |
|
644 | pos += 1 | |
647 |
|
645 | |||
648 | return ''.join(ret) |
|
646 | return ''.join(ret) |
@@ -4085,6 +4085,9 b' Invalid arguments passed to revset()' | |||||
4085 | $ hg log -T '{revset("%whatever", 0)}\n' |
|
4085 | $ hg log -T '{revset("%whatever", 0)}\n' | |
4086 | hg: parse error: unexpected revspec format character w |
|
4086 | hg: parse error: unexpected revspec format character w | |
4087 | [255] |
|
4087 | [255] | |
|
4088 | $ hg log -T '{revset("%lwhatever", files)}\n' | |||
|
4089 | hg: parse error: unexpected revspec format character w | |||
|
4090 | [255] | |||
4088 |
|
4091 | |||
4089 | Test files function |
|
4092 | Test files function | |
4090 |
|
4093 |
General Comments 0
You need to be logged in to leave comments.
Login now