aboutsummaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2011-11-19 19:22:13 +0000
committerDouglas Gregor <dgregor@apple.com>2011-11-19 19:22:13 +0000
commit1a026803b7886ed265fc63dfddaaa5d3712760e3 (patch)
tree78d9ff9334f4cfd3bd901ce80bf38b0610fa4cab /examples
parent8b06d6b95b133822b5ac6a382843c39a689569b4 (diff)
Update signature of HandleTopLevelDecl.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145001 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'examples')
-rw-r--r--examples/PrintFunctionNames/PrintFunctionNames.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/examples/PrintFunctionNames/PrintFunctionNames.cpp b/examples/PrintFunctionNames/PrintFunctionNames.cpp
index fde60955aa..ce8f208e41 100644
--- a/examples/PrintFunctionNames/PrintFunctionNames.cpp
+++ b/examples/PrintFunctionNames/PrintFunctionNames.cpp
@@ -23,12 +23,14 @@ namespace {
class PrintFunctionsConsumer : public ASTConsumer {
public:
- virtual void HandleTopLevelDecl(DeclGroupRef DG) {
+ virtual bool HandleTopLevelDecl(DeclGroupRef DG) {
for (DeclGroupRef::iterator i = DG.begin(), e = DG.end(); i != e; ++i) {
const Decl *D = *i;
if (const NamedDecl *ND = dyn_cast<NamedDecl>(D))
llvm::errs() << "top-level-decl: \"" << ND->getNameAsString() << "\"\n";
}
+
+ return true;
}
};