diff options
author | Takayuki Shimizukawa <shimizukawa@gmail.com> | 2014-04-29 23:44:12 +0900 |
---|---|---|
committer | Takayuki Shimizukawa <shimizukawa@gmail.com> | 2014-04-29 23:44:12 +0900 |
commit | 00eff0b7f656b5212b6f4d2c567f6828ee81ee82 (patch) | |
tree | c2c9028bcde9a51b75743a7b00d298da59e86e03 /sphinx/util/pycompat.py | |
parent | 91b9d75ac88afc349de4f8629b99c7fbcb3ff841 (diff) | |
download | sphinx-git-00eff0b7f656b5212b6f4d2c567f6828ee81ee82.tar.gz |
use six privided text_type() to replace with unicode() to support py2/py3 in one source. refs #1350.
Diffstat (limited to 'sphinx/util/pycompat.py')
-rw-r--r-- | sphinx/util/pycompat.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sphinx/util/pycompat.py b/sphinx/util/pycompat.py index 8d1b3d061..519afe5fe 100644 --- a/sphinx/util/pycompat.py +++ b/sphinx/util/pycompat.py @@ -45,7 +45,7 @@ if six.PY3: lineno, offset = err.context[1] # try to match ParseError details with SyntaxError details raise SyntaxError(err.msg, (filepath, lineno, offset, err.value)) - return unicode(tree) + return six.text_type(tree) from html import escape as htmlescape # >= Python 3.2 else: |