LGTM<div><br></div><div><div>+ if (Char <= 0xff && isprint(Char))</div><div><div>+ OS << (char)Char;</div></div><div><br></div><div>I appreciate this is just copy-pasted, but I noticed that the 'Char <= 0xff' condition is always true here (and the 'else' case can't cope with cases where Char > 0xff either). Maybe remove the 'Char <= 0xff' test?</div>
<br><div class="gmail_quote">On Tue, Jun 12, 2012 at 8:32 PM, Richard Trieu <span dir="ltr"><<a href="mailto:rtrieu@google.com" target="_blank">rtrieu@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
There are several places that crash when processing wchars: the dump methods used for debugging, -ast-dump, and -ast-dump-xml. This was from StmtDumper attempting to get a standard string from StringLiteral, which is only allowed when the string is composed of standard chars. A different visitor, StmtPrinter, already has the logic to nicely print out strings of different types. This patch moves this logic into a function in StringLiteral class and has both StmtDumper and StmtPrinter call this new function.
<br>_______________________________________________<br>
cfe-commits mailing list<br>
<a href="mailto:cfe-commits@cs.uiuc.edu" target="_blank">cfe-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits</a><br>
<br></blockquote></div><br>
</div>