Commit 254f88f8 authored by Alexander Alekhin's avatar Alexander Alekhin

Merge pull request #14759 from alalek:java_gen_unicode

parents 00367289 60fb1fde
......@@ -11,7 +11,12 @@ from string import Template
if sys.version_info[0] >= 3:
from io import StringIO
else:
from cStringIO import StringIO
import io
class StringIO(io.StringIO):
def write(self, s):
if isinstance(s, str):
s = unicode(s) # noqa: F821
return super(StringIO, self).write(s)
SCRIPT_DIR = os.path.dirname(os.path.abspath(__file__))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment