summaryrefslogtreecommitdiffstats
path: root/clang/lib/AST/StmtPrinter.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2008-11-04 14:32:21 +0000
committerDouglas Gregor <dgregor@apple.com>2008-11-04 14:32:21 +0000
commit97a9c81b05ae342ec77743a44eedb9908e8a648f (patch)
tree4dafd4955a6c71fab04acad45c96d33f6ef97661 /clang/lib/AST/StmtPrinter.cpp
parente4f5c9495f2087d73ef926d4d70d1c41311d4501 (diff)
downloadbcm5719-llvm-97a9c81b05ae342ec77743a44eedb9908e8a648f.tar.gz
bcm5719-llvm-97a9c81b05ae342ec77743a44eedb9908e8a648f.zip
Create a new expression class, CXXThisExpr, to handle the C++ 'this' primary expression. Remove CXXThis from PredefinedExpr
llvm-svn: 58695
Diffstat (limited to 'clang/lib/AST/StmtPrinter.cpp')
-rw-r--r--clang/lib/AST/StmtPrinter.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/clang/lib/AST/StmtPrinter.cpp b/clang/lib/AST/StmtPrinter.cpp
index 51f4f518076..34aefc2c4c2 100644
--- a/clang/lib/AST/StmtPrinter.cpp
+++ b/clang/lib/AST/StmtPrinter.cpp
@@ -839,6 +839,10 @@ void StmtPrinter::VisitCXXBoolLiteralExpr(CXXBoolLiteralExpr *Node) {
OS << (Node->getValue() ? "true" : "false");
}
+void StmtPrinter::VisitCXXThisExpr(CXXThisExpr *Node) {
+ OS << "this";
+}
+
void StmtPrinter::VisitCXXThrowExpr(CXXThrowExpr *Node) {
if (Node->getSubExpr() == 0)
OS << "throw";
OpenPOWER on IntegriCloud