zturner added a comment.

On second thought I think the best solution is just to decide that we're
always going to use unicode strings everywhere.  That means using u""
instead of "" everywhere.  It's hard to do this all over the entire
codebase, but we can start with this and see what happens.  This is what I
tried to do in my followup patch the other day, but I think I missed the
place where we were writing self.getvalue() and that was still a regular
string.  So anywhere where we write a string variable and not a string
literal, we still have to decode it conditionally if we're on python 2

The place where we print the traceback, what happens if you do this:

self.session = io.open(path, mode="w", encoding="utf-8")
traceback.print_exc(file=self.session)

Does that work?


http://reviews.llvm.org/D16680



_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to