aboutsummaryrefslogtreecommitdiff
path: root/lib/AST/DeclPrinter.cpp
diff options
context:
space:
mode:
authorAnders Carlsson <andersca@mac.com>2009-09-26 21:58:53 +0000
committerAnders Carlsson <andersca@mac.com>2009-09-26 21:58:53 +0000
commitf88df8652e0726fe9eee5d78f92e3c5b34d0a537 (patch)
treef6f5dcc66e5c657e4e97b39dd1a831412584df8f /lib/AST/DeclPrinter.cpp
parent50dd255e5ad05f0d44bb92f358ff3f541a3d7a4b (diff)
Make Decl::dump const.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82878 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/DeclPrinter.cpp')
-rw-r--r--lib/AST/DeclPrinter.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/AST/DeclPrinter.cpp b/lib/AST/DeclPrinter.cpp
index f448144d28..9d0d836cf6 100644
--- a/lib/AST/DeclPrinter.cpp
+++ b/lib/AST/DeclPrinter.cpp
@@ -77,14 +77,14 @@ namespace {
};
}
-void Decl::print(llvm::raw_ostream &Out, unsigned Indentation) {
+void Decl::print(llvm::raw_ostream &Out, unsigned Indentation) const {
print(Out, getASTContext().PrintingPolicy, Indentation);
}
void Decl::print(llvm::raw_ostream &Out, const PrintingPolicy &Policy,
- unsigned Indentation) {
+ unsigned Indentation) const {
DeclPrinter Printer(Out, getASTContext(), Policy, Indentation);
- Printer.Visit(this);
+ Printer.Visit(const_cast<Decl*>(this));
}
static QualType GetBaseType(QualType T) {
@@ -149,7 +149,7 @@ void Decl::printGroup(Decl** Begin, unsigned NumDecls,
}
}
-void Decl::dump() {
+void Decl::dump() const {
print(llvm::errs());
}