diff options
Diffstat (limited to 'clang/lib/AST/StmtPrinter.cpp')
| -rw-r--r-- | clang/lib/AST/StmtPrinter.cpp | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/clang/lib/AST/StmtPrinter.cpp b/clang/lib/AST/StmtPrinter.cpp index 06514056185..cd206965fb8 100644 --- a/clang/lib/AST/StmtPrinter.cpp +++ b/clang/lib/AST/StmtPrinter.cpp @@ -168,21 +168,9 @@ void StmtPrinter::VisitLabelStmt(LabelStmt *Node) { } void StmtPrinter::VisitAttributedStmt(AttributedStmt *Node) { - std::string raw_attr_os; - llvm::raw_string_ostream AttrOS(raw_attr_os); for (const auto *Attr : Node->getAttrs()) { - // FIXME: This hack will be removed when printPretty - // has been modified to print pretty pragmas - if (const LoopHintAttr *LHA = dyn_cast<LoopHintAttr>(Attr)) { - LHA->print(OS, Policy); - } else - Attr->printPretty(AttrOS, Policy); - } - - // Print attributes after pragmas. - StringRef AttrStr = AttrOS.str(); - if (!AttrStr.empty()) - OS << AttrStr; + Attr->printPretty(OS, Policy); + } PrintStmt(Node->getSubStmt(), 0); } |

