Mercurial > public > mercurial-scm > hg-stable
diff mercurial/byterange.py @ 34146:0fa781320203
doctest: bulk-replace string literals with b'' for Python 3
Our code transformer can't rewrite string literals in docstrings, and I
don't want to make the transformer more complex.
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Sun, 03 Sep 2017 14:32:11 +0900 |
parents | 032c4c2f802a |
children | 635553ca6eb9 |
line wrap: on
line diff
--- a/mercurial/byterange.py Thu Sep 07 22:36:54 2017 +0900 +++ b/mercurial/byterange.py Sun Sep 03 14:32:11 2017 +0900 @@ -91,7 +91,7 @@ Examples: # expose 10 bytes, starting at byte position 20, from # /etc/aliases. - >>> fo = RangeableFileObject(file('/etc/passwd', 'r'), (20,30)) + >>> fo = RangeableFileObject(file(b'/etc/passwd', b'r'), (20,30)) # seek seeks within the range (to position 23 in this case) >>> fo.seek(3) # tell tells where your at _within the range_ (position 3 in