[5.0] IRGen: Empty fields do have an entry in the field offset vector #13906
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is an error introduced as the result of a refactoring a while ago
and means that we will store dependently typed stored properties at the
wrong offset in a generic struct if it has stored properties of empty
types before said property.
Explanation: We would compute the wrong offset for dependently typed properties inside generic structs if said property was preceded by a stored property of empty type.
Scope: This was introduced as the result of a refactoring in the swift-4.1-branch timeframe.
Risk: Low. Single line change that only applies to empty types when we compute their offset in the field offset vector.
Testing: Swift CI Tests added.
rdar://36384871