Skip to content

Commit 2475095

Browse files
committed
Remove Ranges File Type
1 parent d427d38 commit 2475095

22 files changed

+8
-716
lines changed

include/swift/AST/DiagnosticsDriver.def

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -155,13 +155,9 @@ WARNING(warn_use_filelists_deprecated, none,
155155
"the option '-driver-use-filelists' is deprecated; use "
156156
"'-driver-filelist-threshold=0' instead", ())
157157

158-
WARNING(warn_unable_to_load_swift_ranges, none,
159-
"unable to load swift ranges file \"%0\", %1",
160-
(StringRef, StringRef))
161-
162158
WARNING(warn_unable_to_load_compiled_swift, none,
163-
"unable to load previously compiled swift file \"%0\", %1",
164-
(StringRef, StringRef))
159+
"unable to load previously compiled swift file \"%0\", %1",
160+
(StringRef, StringRef))
165161

166162
WARNING(warn_unable_to_load_primary, none,
167163
"unable to load primary swift file \"%0\", %1",

include/swift/AST/DiagnosticsFrontend.def

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -109,10 +109,8 @@ ERROR(error_mode_cannot_emit_dependencies,none,
109109
"this mode does not support emitting dependency files", ())
110110
ERROR(error_mode_cannot_emit_reference_dependencies,none,
111111
"this mode does not support emitting reference dependency files", ())
112-
ERROR(error_mode_cannot_emit_swift_ranges,none,
113-
"this mode does not support emitting unparsed ranges files", ())
114112
ERROR(error_mode_cannot_emit_compiled_source,none,
115-
"this mode does not support emitting compiled source files", ())
113+
"this mode does not support emitting compiled source files", ())
116114
ERROR(error_mode_cannot_emit_header,none,
117115
"this mode does not support emitting Objective-C headers", ())
118116
ERROR(error_mode_cannot_emit_loaded_module_trace,none,
@@ -132,11 +130,9 @@ ERROR(cannot_emit_ir_skipping_function_bodies,none,
132130
"emitting IR", ())
133131

134132
WARNING(emit_reference_dependencies_without_primary_file,none,
135-
"ignoring -emit-reference-dependencies (requires -primary-file)", ())
136-
WARNING(emit_swift_ranges_without_primary_file,none,
137-
"ignoring -emit-swift-ranges (requires -primary-file)", ())
133+
"ignoring -emit-reference-dependencies (requires -primary-file)", ())
138134
WARNING(emit_compiled_source_without_primary_file,none,
139-
"ignoring -emit-compiled-source (requires -primary-file)", ())
135+
"ignoring -emit-compiled-source (requires -primary-file)", ())
140136

141137
ERROR(error_bad_module_name,none,
142138
"module name \"%0\" is not a valid identifier"
@@ -336,12 +332,8 @@ ERROR(error_invalid_coverage_prefix_map, none,
336332
"values for '-coverage-prefix-map' must be in the format "
337333
"'original=remapped', but '%0' was provided", (StringRef))
338334

339-
340-
ERROR(error_unable_to_write_swift_ranges_file, none,
341-
"unable to write unparsed ranges file '$0': %1", (StringRef, StringRef))
342-
343335
ERROR(error_unable_to_write_compiled_source_file, none,
344-
"unable to write compiled source file: '$0': %1", (StringRef, StringRef))
336+
"unable to write compiled source file: '$0': %1", (StringRef, StringRef))
345337

346338

347339
ERROR(invalid_vfs_overlay_file,none,

include/swift/AST/IncrementalRanges.h

Lines changed: 0 additions & 277 deletions
This file was deleted.

include/swift/Basic/FileTypes.def

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,6 @@ TYPE("diagnostics", SerializedDiagnostics, "dia", "")
6262
TYPE("objc-header", ObjCHeader, "h", "")
6363
TYPE("swift-dependencies", SwiftDeps, "swiftdeps", "")
6464
TYPE("external-swift-dependencies", ExternalSwiftDeps, "swiftdeps.external", "")
65-
TYPE("swift-ranges", SwiftRanges, "swiftranges", "")
6665
TYPE("compiled-source", CompiledSource, "compiledsource", "")
6766
TYPE("remap", Remapping, "remap", "")
6867
TYPE("imported-modules", ImportedModules, "importedmodules", "")

include/swift/Basic/FileTypes.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ static inline void forAllTypes(llvm::function_ref<void(file_types::ID)> fn) {
6969
static inline void
7070
forEachIncrementalOutputType(llvm::function_ref<void(file_types::ID)> fn) {
7171
static const std::vector<file_types::ID> incrementalOutputTypes = {
72-
file_types::TY_SwiftDeps, file_types::TY_SwiftRanges,
72+
file_types::TY_SwiftDeps,
7373
file_types::TY_CompiledSource};
7474
for (auto type : incrementalOutputTypes)
7575
fn(type);

include/swift/Basic/SupplementaryOutputPaths.h

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -83,18 +83,6 @@ struct SupplementaryOutputPaths {
8383
/// \sa DependencyGraph
8484
std::string ReferenceDependenciesFilePath;
8585

86-
/// The path to which we should output a Swift "unparsed ranges" file.
87-
/// It is valid whenever there are any inputs.
88-
///
89-
/// "Unparsed ranges" track source ranges in non-primary files whose parsing
90-
/// was skipped
91-
/// (a.k.a. "delayed).\
92-
/// These files are consumed by the Swift driver (or will be someday) to
93-
/// decide whether a source file needs to be recompiled during a build.
94-
///
95-
/// \sa swift::emitSwiftRanges
96-
std::string SwiftRangesFilePath;
97-
9886
/// The path to which we should save the source code of a primary source file
9987
/// to be compiled. Used to diff sources of primary inputs.
10088
std::string CompiledSourceFilePath;
@@ -186,8 +174,6 @@ struct SupplementaryOutputPaths {
186174
fn(DependenciesFilePath);
187175
if (!ReferenceDependenciesFilePath.empty())
188176
fn(ReferenceDependenciesFilePath);
189-
if (!SwiftRangesFilePath.empty())
190-
fn(SwiftRangesFilePath);
191177
if (!CompiledSourceFilePath.empty())
192178
fn(CompiledSourceFilePath);
193179
if (!SerializedDiagnosticsPath.empty())

include/swift/Frontend/Frontend.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,6 @@ class CompilerInvocation {
362362
std::string getModuleOutputPathForAtMostOnePrimary() const;
363363
std::string
364364
getReferenceDependenciesFilePathForPrimary(StringRef filename) const;
365-
std::string getSwiftRangesFilePathForPrimary(StringRef filename) const;
366365
std::string getCompiledSourceFilePathForPrimary(StringRef filename) const;
367366
std::string getSerializedDiagnosticsPathForAtMostOnePrimary() const;
368367

@@ -652,11 +651,6 @@ class CompilerInstance {
652651
const PrimarySpecificPaths &
653652
getPrimarySpecificPathsForSourceFile(const SourceFile &SF) const;
654653

655-
/// Write out the unparsed (delayed) source ranges
656-
/// Return true for error
657-
bool emitSwiftRanges(DiagnosticEngine &diags, SourceFile *primaryFile,
658-
StringRef outputPath) const;
659-
660654
/// Return true for error
661655
bool emitCompiledSource(DiagnosticEngine &diags,
662656
const SourceFile *primaryFile,

0 commit comments

Comments
 (0)