-
Notifications
You must be signed in to change notification settings - Fork 116
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix duplicated diagnostic issue #733
Conversation
b5fbd86
to
cf59e07
Compare
@swift-ci please test |
cf59e07
to
80deede
Compare
@swift-ci please test |
Tests/SwiftDocCTests/Semantics/MarkupReferenceResolverTests.swift
Outdated
Show resolved
Hide resolved
This looks good to me. @binamaniar can you take a second look at this while I'm out? |
@swift-ci please test |
Ping @binamaniar |
@d-ronnqvist I'd like to confirm whether we should wait for binamaniar's approval before the merging. |
sorry for the late reply. Looks good to me to make sure there is no crash when the location is not in source. Just thinking do we need to need an extra check that it is for extension files only. My answer is probably no but sharing my thought. I don't see any other scenario where we would run into this. |
There is not too much context to get the info(whether it is an extension file) now. We may consider adding the extra check later if needed. Anyway, thanks for the review suggestion. |
If the range’s source is not matched with the resolver’s source, we should not emit a problem
Co-authored-by: David Rönnqvist <david.ronnqvist@gmail.com>
Co-authored-by: David Rönnqvist <david.ronnqvist@gmail.com>
Co-authored-by: David Rönnqvist <david.ronnqvist@gmail.com>
003e5c5
to
b987502
Compare
@swift-ci please test |
* Fix duplicated diagnostic issue If the range’s source is not matched with the resolver’s source, we should not emit a problem * Add test case for duplicated diagnostic issue * Update Sources/SwiftDocC/Semantics/MarkupReferenceResolver.swift Co-authored-by: David Rönnqvist <david.ronnqvist@gmail.com> * Update Tests/SwiftDocCTests/Semantics/MarkupReferenceResolverTests.swift Co-authored-by: David Rönnqvist <david.ronnqvist@gmail.com> * Update Tests/SwiftDocCTests/Semantics/MarkupReferenceResolverTests.swift Co-authored-by: David Rönnqvist <david.ronnqvist@gmail.com> --------- Co-authored-by: David Rönnqvist <david.ronnqvist@gmail.com>
* Fix duplicated diagnostic issue If the range’s source is not matched with the resolver’s source, we should not emit a problem * Add test case for duplicated diagnostic issue * Update Sources/SwiftDocC/Semantics/MarkupReferenceResolver.swift * Update Tests/SwiftDocCTests/Semantics/MarkupReferenceResolverTests.swift * Update Tests/SwiftDocCTests/Semantics/MarkupReferenceResolverTests.swift --------- Co-authored-by: David Rönnqvist <david.ronnqvist@gmail.com>
Bug/issue #, if applicable:
Close #729 and rdar://79991171
Summary
If the range’s source is not matched with the resolver’s source, we should not emit a problem
Dependencies
None
Testing
See
func testDuplicatedDiagnosticForExtensionFile()
inMarkupReferenceResolverTests.swift
Checklist
Make sure you check off the following items. If they cannot be completed, provide a reason.
./bin/test
script and it succeeded