clang: lib/StaticAnalyzer/Frontend/ModelConsumer.cpp Source File (original) (raw)
Go to the documentation of this file.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
24
25using namespace clang;
26using namespace ento;
27
29 : Bodies(Bodies) {}
30
33
34 const auto *func = llvm::dyn_cast(D);
35 if (func && func->hasBody()) {
36 Bodies.insert(std::make_pair(func->getName(), func->getBody()));
37 }
38 }
39 return true;
40}
This file implements clang::ento::ModelConsumer which is an ASTConsumer for model files.
Decl - This represents one declaration (or definition), e.g.
bool HandleTopLevelDecl(DeclGroupRef D) override
HandleTopLevelDecl - Handle the specified top-level declaration.
ModelConsumer(llvm::StringMap< Stmt * > &Bodies)
The JSON file list parser is used to communicate input to InstallAPI.