aboutsummaryrefslogtreecommitdiff
path: root/AST/StmtPrinter.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'AST/StmtPrinter.cpp')
-rw-r--r--AST/StmtPrinter.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/AST/StmtPrinter.cpp b/AST/StmtPrinter.cpp
index 81bad22a7e..2bdeadfbef 100644
--- a/AST/StmtPrinter.cpp
+++ b/AST/StmtPrinter.cpp
@@ -455,6 +455,17 @@ void StmtPrinter::VisitObjCAtThrowStmt (ObjCAtThrowStmt *Node) {
OS << ";\n";
}
+void StmtPrinter::VisitObjCAtSynchronizedStmt (ObjCAtSynchronizedStmt *Node) {
+ Indent() << "@synchronized (";
+ PrintExpr(Node->getSynchExpr());
+ OS << ")";
+ if (CompoundStmt *CS = dyn_cast<CompoundStmt>(Node->getSynchBody()))
+ {
+ PrintRawCompoundStmt(CS);
+ OS << "\n";
+ }
+}
+
//===----------------------------------------------------------------------===//
// Expr printing methods.
//===----------------------------------------------------------------------===//