clang: include/clang/Tooling/DependencyScanning/DependencyScanningTool.h Source File (original) (raw)
1
2
3
4
5
6
7
8
9#ifndef LLVM_CLANG_TOOLING_DEPENDENCYSCANNING_DEPENDENCYSCANNINGTOOL_H
10#define LLVM_CLANG_TOOLING_DEPENDENCYSCANNING_DEPENDENCYSCANNINGTOOL_H
11
16#include "llvm/ADT/DenseSet.h"
17#include "llvm/ADT/MapVector.h"
18#include
19#include
20#include
21#include
22
24namespace tooling {
25namespace dependencies {
26
27
30
31
33
34
36
38
39
40
41
43
44
45
47
48
49
51
52
53
54
55
56
58
59
60
61
62
63
64
66
67
69};
70
75};
76
77
78
80public:
81
84 llvm::vfs::createPhysicalFileSystem());
85
86
87
88
89
90
91
93 getDependencyFile(const std::vectorstd::string &CommandLine, StringRef CWD);
94
95
96
97
98
99
100
101
102
103
104
105
108 StringRef CWD, std::string &MakeformatOutput,
109 std::string &MakeformatOutputPath);
112 StringRef CWD) {
113 std::string MakeformatOutput;
114 std::string MakeformatOutputPath;
115
117 MakeformatOutputPath);
118 }
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
136 StringRef CWD,
137 const llvm::DenseSet &AlreadySeen,
139
140
141
142
144 StringRef ModuleName, const std::vectorstd::string &CommandLine,
145 StringRef CWD, const llvm::DenseSet &AlreadySeen,
147
149
150private:
152};
153
155public:
157 : AlreadySeen(AlreadySeen) {}
158
160 Commands.push_back(std::move(Cmd));
161 }
162
164
166 Dependencies.push_back(std::string(File));
167 }
168
170 PrebuiltModuleDeps.emplace_back(std::move(PMD));
171 }
172
174 ClangModuleDeps[MD.ID] = std::move(MD);
175 }
176
178 DirectModuleDeps.push_back(ID);
179 }
180
182 ContextHash = std::move(Hash);
183 }
184
187
188private:
189 std::vectorstd::string Dependencies;
190 std::vector PrebuiltModuleDeps;
191 llvm::MapVector<ModuleID, ModuleDeps> ClangModuleDeps;
192 std::vector DirectModuleDeps;
193 std::vector Commands;
194 std::string ContextHash;
195 std::vectorstd::string OutputPaths;
196 const llvm::DenseSet &AlreadySeen;
197};
198
199
200
202public:
204
206 : LookupModuleOutput(std::move(LMO)) {
207 if (!LookupModuleOutput) {
208 LookupModuleOutput = [](const ModuleID &,
210 llvm::report_fatal_error("unexpected call to lookupModuleOutput");
211 };
212 }
213 }
214
217 return LookupModuleOutput(ID, Kind);
218 }
219
220private:
222};
223
224}
225}
226}
227
228#endif
enum clang::sema::@1727::IndirectLocalPathEntry::EntryKind Kind
DependencyOutputOptions - Options for controlling the compiler dependency file generation.
The JSON file list parser is used to communicate input to InstallAPI.