Closed GoogleCodeExporter closed 9 years ago
sure, it doesn't consider the unicode issue, and use ascii encoding by default,
I will fix
it soon, thanks :)
Original comment by flier...@gmail.com
on 22 Apr 2009 at 4:45
I have added some convert code which support the bi-way automatic conversion
with UTF-8 encoding
def testUnicode(self):
with JSContext() as ctxt:
self.assertEquals(u"人", unicode(ctxt.eval("\"人\""), "utf-8"))
self.assertEquals(u"é", unicode(ctxt.eval("\"é\""), "utf-8"))
func = ctxt.eval("function (msg) { return msg.length; }")
self.assertEquals(2, func(u"测试"))
please check the change list for more detail, thanks :)
http://code.google.com/p/pyv8/source/detail?r=119
Original comment by flier...@gmail.com
on 22 Apr 2009 at 9:18
Original issue reported on code.google.com by
fabienow...@gmail.com
on 21 Apr 2009 at 9:22Attachments: