Skip to content

Commit 876d689

Browse files
committed
[NFC] Rework serialization changes in swiftlang#32811
This tweaks the implementation of SE-0285 to preserve backwards compatibility with the previous module serialization format. Existing default arguments all keep their previous values when serialized; #fileID and Swift 6 #file are given previously unused values. Fixes rdar://66810027.
1 parent df007a4 commit 876d689

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lib/Serialization/ModuleFormat.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ const uint16_t SWIFTMODULE_VERSION_MAJOR = 0;
5555
/// describe what change you made. The content of this comment isn't important;
5656
/// it just ensures a conflict if two people change the module format.
5757
/// Don't worry about adhering to the 80-column limit for this line.
58-
const uint16_t SWIFTMODULE_VERSION_MINOR = 557; // #fileID
58+
const uint16_t SWIFTMODULE_VERSION_MINOR = 556; // Serialization of -implicit-dynamic
5959

6060
/// A standard hash seed used for all string hashes in a serialized module.
6161
///
@@ -459,10 +459,8 @@ using ValueOwnershipField = BCFixed<2>;
459459
enum class DefaultArgumentKind : uint8_t {
460460
None = 0,
461461
Normal,
462-
FileID,
463-
FilePath,
464-
FileIDSpelledAsFile,
465462
FilePathSpelledAsFile,
463+
FilePath,
466464
Line,
467465
Column,
468466
Function,
@@ -472,6 +470,8 @@ enum class DefaultArgumentKind : uint8_t {
472470
EmptyArray,
473471
EmptyDictionary,
474472
StoredProperty,
473+
FileIDSpelledAsFile,
474+
FileID
475475
};
476476
using DefaultArgumentField = BCFixed<4>;
477477

0 commit comments

Comments
 (0)