Error when #[doc(alias)] has same name as the item#80686
Merged
bors merged 2 commits intorust-lang:masterfrom Jan 5, 2021
Merged
Error when #[doc(alias)] has same name as the item#80686bors merged 2 commits intorust-lang:masterfrom
bors merged 2 commits intorust-lang:masterfrom
Conversation
jyn514
reviewed
Jan 4, 2021
src/test/ui/doc-alias-same-name.rs
Outdated
Member
There was a problem hiding this comment.
Hmm, I didn't realize this runs in rustc_attr itself. It shouldn't be changed here, but I wonder if it makes sense to run those checks in rustdoc instead?
Member
Author
There was a problem hiding this comment.
It's scheduled for later. :)
0ecf7da to
9714ac0
Compare
Member
Author
|
Updated! |
Member
|
@bors r+ |
Collaborator
|
📌 Commit 9714ac0 has been approved by |
Collaborator
Collaborator
|
☀️ Test successful - checks-actions |
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Jan 6, 2021
…as-feature, r=jyn514 Remove useless doc_alias feature gate As `@jyn514` rightfully noted in rust-lang#80686 , this feature is no more. Therefore, cleanup time! r? `@jyn514`
tesuji
reviewed
Jan 6, 2021
| return false; | ||
| } | ||
| let item_name = self.tcx.hir().name(hir_id); | ||
| if item_name.to_string() == doc_alias { |
Contributor
There was a problem hiding this comment.
Does it really need to_string to compare between an Symbol and a string?
Member
Author
There was a problem hiding this comment.
You're absolutely right, I opened #80750 to fix it.
Dylan-DPC-zz
pushed a commit
to Dylan-DPC-zz/rust
that referenced
this pull request
Jan 7, 2021
…=lzutao Don't use to_string on Symbol in rustc_passes/check_attr.rs Improve code from rust-lang#80686. r? `@lzutao`
JohnTitor
added a commit
to JohnTitor/rust
that referenced
this pull request
Jan 7, 2021
…=lzutao Don't use to_string on Symbol in rustc_passes/check_attr.rs Improve code from rust-lang#80686. r? ``@lzutao``
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Something I came across when reviewing some doc alias PRs.
r? @jyn514