-
Notifications
You must be signed in to change notification settings - Fork 14k
Rollup of 3 pull requests #149290
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
Open
matthiaskrgr
wants to merge
15
commits into
rust-lang:main
Choose a base branch
from
matthiaskrgr:rollup-74v8k3e
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Rollup of 3 pull requests #149290
+374
−161
Conversation
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
…od_error Currently this method is quiet long and complex, this commit refactors it and improves its readability by adding sub-fn
…thod_error Currently this method is quiet long and complex, this commit refactors it and improves its readability by adding sub-fn
…hod_error Currently this method is quiet long and complex, this commit refactors it and improves its readability by adding sub-fn
…d_error Currently this method is quiet long and complex, this commit refactors it and improves its readability by adding sub-fn
…o_match_method_error Currently this method is quiet long and complex, this commit refactors it and improves its readability by adding sub-fn
…t_no_match_method_error Currently this method is quiet long and complex, this commit refactors it and improves its readability by adding sub-fn
…eport_no_match_method_error Currently this method is quiet long and complex, this commit refactors it and improves its readability by adding sub-fn
Currently this method is quiet long and complex, this commit improves its readability, refactor and cleanup few things
Co-authored-by: Vadim Petrochenkov <vadim.petrochenkov@gmail.com>
…or-refactoring, r=lcnr Cleanup and refactor FnCtxt::report_no_match_method_error As discussed on zulip with `@lcnr,` this is a proposal for refactorizing this method. See [#t-compiler/help > (PR rust-lang#144674) Merge multiple suggestions into a single @ 💬](https://rust-lang.zulipchat.com/#narrow/channel/182449-t-compiler.2Fhelp/topic/.28PR.20.23144674.29.20Merge.20multiple.20suggestions.20into.20a.20single/near/539991695)
…henkov Add test for derive helper compat collisions Resolves rust-lang/reference#2055 (comment) r? `@petrochenkov`
…, r=lolbinarycat Fix invalid link generation for type alias methods Fixes rust-lang#149205. That one was quite the wild ride. First commit is the actual fix, the second commit is just a small name variable improvement while I was going through the code. Anyway, let's go through it: * We don't generate directly implementations in the HTML files for local impls (which I think is a mistake and should be changed, gonna do that as a follow-up) but instead generate a JS file for each type alias containing the HTML for these impls. * So in `write_shared.rs::TypeAliasPart::get`, when generating the JS file, we generate the impl into a `String` by calling `render_impl`. This method expects an `AssocItemLink` to help it generate the correct link to the item (I'm planning to also remove this enum because it's yet another way to generate anchors/hrefs). * Problem was: we call the `provided_trait_methods` method on the impl item... which is empty if not a trait impl. This becomes an issue when we arrive in `render::assoc_href_attr` because of this code: ```rust AssocItemLink::GotoSource(did, provided_methods) => { let item_type = match item_type { ItemType::Method | ItemType::TyMethod => { if provided_methods.contains(&name) { ItemType::Method } else { ItemType::TyMethod } } item_type => item_type, }; // ... } ``` Since `provided_methods` is always empty, it means all methods on type aliases will be `TyMethod`, generating `#tymethod.` URLs instead of `#method.`. * So generating `AssocItemLink::GoToSource` only on traits (when `provided_trait_methods` is supposed to return something) was the fix. * And finally, because it's (currently) generating implementations only through JS, it means we cannot test it in `tests/rustdoc` so I had to write the test in `tests/rustdoc-gui`. Once I change how we generate local implementations for type aliases, I'll move it to `tests/rustdoc`. r? `@lolbinarycat`
Member
Author
|
@bors r+ rollup=never p=5 |
Collaborator
Collaborator
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
rollup
A PR which is a rollup
S-waiting-on-bors
Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
T-rustdoc
Relevant to the rustdoc team, which will review and decide on the PR/issue.
T-rustdoc-frontend
Relevant to the rustdoc-frontend team, which will review and decide on the web UI/UX output.
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.
Successful merges:
r? @ghost
@rustbot modify labels: rollup
Create a similar rollup