Mercurial > hg-stable
changeset 30073:aa23c93e636d
py3: make format strings unicodes and not bytes
Fixes issues on Python 3, wherein docstrings are unicodes.
Shouldn't break anything on Python 2.
author | Pulkit Goyal <7895pulkit@gmail.com> |
---|---|
date | Sat, 08 Oct 2016 16:10:58 +0200 |
parents | 87b8e40eb812 |
children | 8f34e217338b |
files | mercurial/filemerge.py |
diffstat | 1 files changed, 3 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/filemerge.py Fri Oct 07 17:30:11 2016 +0200 +++ b/mercurial/filemerge.py Sat Oct 08 16:10:58 2016 +0200 @@ -19,6 +19,7 @@ error, formatter, match, + pycompat, scmutil, simplemerge, tagmerge, @@ -93,7 +94,8 @@ '''return a decorator for populating internal merge tool table''' def decorator(func): fullname = ':' + name - func.__doc__ = "``%s``\n" % fullname + func.__doc__.strip() + func.__doc__ = (pycompat.sysstr("``%s``\n" % fullname) + + func.__doc__.strip()) internals[fullname] = func internals['internal:' + name] = func internalsdoc[fullname] = func