[cfe-commits] [Patch] Fix crash when attempting to dump a StringLiteral with wchar's in it.

Richard Trieu rtrieu at google.com
Tue Jun 12 20:32:36 PDT 2012


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.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120612/001c4c38/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: wchar-ast-dump.patch
Type: application/octet-stream
Size: 9265 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120612/001c4c38/attachment.obj>


More information about the cfe-commits mailing list