summaryrefslogtreecommitdiff
path: root/include/clang/Analysis/CallGraph.h
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2017-04-16 16:02:28 +0000
committerDimitry Andric <dim@FreeBSD.org>2017-04-16 16:02:28 +0000
commit7442d6faa2719e4e7d33a7021c406c5a4facd74d (patch)
treec72b9241553fc9966179aba84f90f17bfa9235c3 /include/clang/Analysis/CallGraph.h
parentb52119637f743680a99710ce5fdb6646da2772af (diff)
Diffstat (limited to 'include/clang/Analysis/CallGraph.h')
-rw-r--r--include/clang/Analysis/CallGraph.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/clang/Analysis/CallGraph.h b/include/clang/Analysis/CallGraph.h
index b8ae67cbba494..a2a27a8e47c75 100644
--- a/include/clang/Analysis/CallGraph.h
+++ b/include/clang/Analysis/CallGraph.h
@@ -98,7 +98,7 @@ public:
bool VisitFunctionDecl(FunctionDecl *FD) {
// We skip function template definitions, as their semantics is
// only determined when they are instantiated.
- if (includeInGraph(FD)) {
+ if (includeInGraph(FD) && FD->isThisDeclarationADefinition()) {
// Add all blocks declared inside this function to the graph.
addNodesForBlocks(FD);
// If this function has external linkage, anything could call it.