Fix diagnostics in Objective-C documentation comments appearing on the wrong line #949
+43
−154
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.
Bug/issue #, if applicable: rdar://129668876
Summary
Now that Clang and Swift emits source ranges for documentation comments the same, we need to remove the DocC workaround that offset Objective-C ranges, otherwise diagnostics for Objective-C documentation comments will appear on the wrong line.
Dependencies
None
Testing
Add some content that will result in warnings to an Objective-C documentation comment and build documentation for it. For example:
The various warnings should display for the correct line and column ranges.
Checklist
Make sure you check off the following items. If they cannot be completed, provide a reason.
./bin/test
script and it succeededUpdated documentation if necessaryNot applicable