@@ -87,14 +87,15 @@ class DependencyScanningTool {
87
87
// / occurred, \c swiftscan_dependency_result_t otherwise.
88
88
llvm::ErrorOr<swiftscan_dependency_graph_t >
89
89
getDependencies (ArrayRef<const char *> Command,
90
- const llvm::StringSet<> &PlaceholderModules);
90
+ const llvm::StringSet<> &PlaceholderModules,
91
+ StringRef WorkingDirectory);
91
92
92
93
// / Collect the set of imports for the input module
93
94
// /
94
95
// / \returns a \c StringError with the diagnostic output if errors
95
96
// / occurred, \c swiftscan_prescan_result_t otherwise.
96
97
llvm::ErrorOr<swiftscan_import_set_t >
97
- getImports (ArrayRef<const char *> Command);
98
+ getImports (ArrayRef<const char *> Command, StringRef WorkingDirectory );
98
99
99
100
// / Collect the full module dependency graph for the input collection of
100
101
// / module names (batch inputs) and output them to the
@@ -104,7 +105,8 @@ class DependencyScanningTool {
104
105
std::vector<llvm::ErrorOr<swiftscan_dependency_graph_t >>
105
106
getDependencies (ArrayRef<const char *> Command,
106
107
const std::vector<BatchScanInput> &BatchInput,
107
- const llvm::StringSet<> &PlaceholderModules);
108
+ const llvm::StringSet<> &PlaceholderModules,
109
+ StringRef WorkingDirectory);
108
110
109
111
// / Writes the current `SharedCache` instance to a specified FileSystem path.
110
112
void serializeCache (llvm::StringRef path);
@@ -121,13 +123,15 @@ class DependencyScanningTool {
121
123
// / Using the specified invocation command, instantiate a CompilerInstance
122
124
// / that will be used for this scan.
123
125
llvm::ErrorOr<ScanQueryInstance>
124
- initCompilerInstanceForScan (ArrayRef<const char *> Command);
126
+ initCompilerInstanceForScan (ArrayRef<const char *> Command,
127
+ StringRef WorkingDirectory);
125
128
126
129
private:
127
130
// / Using the specified invocation command, initialize the scanner instance
128
131
// / for this scan. Returns the `CompilerInstance` that will be used.
129
132
llvm::ErrorOr<ScanQueryInstance>
130
- initScannerForAction (ArrayRef<const char *> Command);
133
+ initScannerForAction (ArrayRef<const char *> Command,
134
+ StringRef WorkingDirectory);
131
135
132
136
// / Shared cache of module dependencies, re-used by individual full-scan queries
133
137
// / during the lifetime of this Tool.
0 commit comments