From e33c116bdf89b683200fabdd9d4e459e6ddf0b8a Mon Sep 17 00:00:00 2001 From: Fariborz Jahanian Date: Wed, 30 Jun 2010 16:31:08 +0000 Subject: Nasty rewriter bug which turns out to have an easy fix in rewriting a c-style cast expression in statement printer. Fixes radar 8143056. llvm-svn: 107289 --- clang/lib/AST/StmtPrinter.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'clang/lib/AST/StmtPrinter.cpp') diff --git a/clang/lib/AST/StmtPrinter.cpp b/clang/lib/AST/StmtPrinter.cpp index 9bef49c3984..c259b4c951a 100644 --- a/clang/lib/AST/StmtPrinter.cpp +++ b/clang/lib/AST/StmtPrinter.cpp @@ -802,7 +802,7 @@ void StmtPrinter::VisitExplicitCastExpr(ExplicitCastExpr *) { assert(0 && "ExplicitCastExpr is an abstract class"); } void StmtPrinter::VisitCStyleCastExpr(CStyleCastExpr *Node) { - OS << "(" << Node->getType().getAsString() << ")"; + OS << "(" << Node->getType().getAsString(Policy) << ")"; PrintExpr(Node->getSubExpr()); } void StmtPrinter::VisitCompoundLiteralExpr(CompoundLiteralExpr *Node) { -- cgit v1.2.3