Skip to content

Commit d402292

Browse files
committed
[NFC] Mark Result as move-only
This required dropping some superfluous 'const' qualification in the module dependency graph.
1 parent 3ecb0b0 commit d402292

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

include/swift/Driver/Compilation.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,12 @@ class Compilation {
8484
bool hadAbnormalExit;
8585
int exitCode;
8686
fine_grained_dependencies::ModuleDepGraph depGraph;
87+
88+
Result(const Result &) = delete;
89+
Result(Result &&) = default;
90+
91+
Result &operator=(const Result &) = delete;
92+
Result &operator=(Result &&) = default;
8793
};
8894

8995
class IncrementalSchemeComparator {

include/swift/Driver/FineGrainedDependencyDriverGraph.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -188,8 +188,8 @@ class ModuleDepGraph {
188188
std::unordered_map<std::string, unsigned> dotFileSequenceNumber;
189189

190190
public:
191-
const bool verifyFineGrainedDependencyGraphAfterEveryImport;
192-
const bool emitFineGrainedDependencyDotFileAfterEveryImport;
191+
bool verifyFineGrainedDependencyGraphAfterEveryImport;
192+
bool emitFineGrainedDependencyDotFileAfterEveryImport;
193193

194194
private:
195195
/// If tracing dependencies, holds a vector used to hold the current path
@@ -203,7 +203,7 @@ class ModuleDepGraph {
203203
dependencyPathsToJobs;
204204

205205
/// For helping with performance tuning, may be null:
206-
UnifiedStatsReporter *const stats;
206+
UnifiedStatsReporter *stats;
207207

208208
//==============================================================================
209209
// MARK: ModuleDepGraph - mutating dependencies

0 commit comments

Comments
 (0)