-
Notifications
You must be signed in to change notification settings - Fork 13k
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
Rollup of 10 pull requests #134414
Rollup of 10 pull requests #134414
Conversation
By making the variable names more descriptive it becomes easier to understand the code. Especially with the more complicated code in the next commit.
Since the previos commit renamed `assignment_rhs_span` to just `rhs_span` there is no need for a variable just to shorten the expression on the next line. Inline the variable.
All the other unconditional keywords are in the alphabetical order, but `while` is for some reason not.
`CheckAttrVisitor::check_doc_keyword` checks `#[doc(keyword = "..")]` attributes to ensure they are on an empty module, and that the value is a non-empty identifier. The `rustc::existing_doc_keyword` lint checks these attributes to ensure that the value is the name of a keyword. It's silly to have two different checking mechanisms for these attributes. This commit does the following. - Changes `check_doc_keyword` to check that the value is the name of a keyword (avoiding the need for the identifier check, which removes a dependency on `rustc_lexer`). - Removes the lint. - Updates tests accordingly. There is one hack: the `SelfTy` FIXME case used to used to be handled by disabling the lint, but now is handled with a special case in `is_doc_keyword`. That hack will go away if/when the FIXME is fixed. Co-Authored-By: Guillaume Gomez <guillaume1.gomez@gmail.com>
In rust-lang#129533 the main hash function changed and the order of `-Z input-stats` output changed, which showed that it is dependent on the hash function, even though it is sorted. That's because entries with the same cumulative size are ordered in a way that depends on the hash function. This commit fixes that by using the entry label as the secondary ordering key.
…d, r=GuillaumeGomez Remove `rustc::existing_doc_keyword` lint The check doesn't require a lint. r? ``@GuillaumeGomez``
…ler-errors Handle fndef rendering together with signature rendering Pulled out of rust-lang#134353 Changes some highlighting in type mismatch errors around fndefs
Rename `rustc_mir_build::build` to `builder` GitHub's “Go to file” feature silently ignores all files in this module, presumably because they are in a directory named `build`, which is mistaken for a build-output directory. That makes it meaningfully harder to view those files and their history via GitHub. This PR sidesteps that issue by renaming `build` to `builder`, which in context has basically the same meaning, but can't be mistaken for a build-output directory. --- Extracted from rust-lang#133404, after rust-lang#133592 changed the .gitignore rule from `build/` to `/build`. The problem of GitHub ignoring these files still exists even after that change, which suggests that GitHub's behaviour is a hard-coded heuristic that isn't influenced by the repository's git settings. Currently this PR doesn't include the tidy rule forbidding `build` as a module name, but that could be added if people think it's a good idea.
Use links to edition guide for edition migrations This switches the migration lints for the 2024 edition to point to the edition guide documentation instead of the tracking issues. I expect the documentation should be easier to understand for a user, compared to most of the issues which don't have any direct information, and can be a bit confusing to navigate, or have outdated information.
rustc_borrowck: Suggest changing `&raw const` to `&raw mut` if applicable Closes rust-lang#127562 For reference, here is the diff compared to the original error reported in that issue before rust-lang#134244 stopped suggesting the invalid syntax: ``` diff --git a/tests/ui/borrowck/no-invalid-mut-suggestion-for-raw-pointer-issue-127562.stderr b/tests/ui/borrowck/no-invalid-mut-suggestion-for-raw-pointer-issue-127562.stderr index 0da5d15cf7f..dbe834b6b78 100644 --- a/tests/ui/borrowck/no-invalid-mut-suggestion-for-raw-pointer-issue-127562.stderr +++ b/tests/ui/borrowck/no-invalid-mut-suggestion-for-raw-pointer-issue-127562.stderr ``@@`` -6,8 +6,8 ``@@`` LL | unsafe { *ptr = 3; } | help: consider changing this to be a mutable pointer | -LL | let ptr = &mut raw const val; - | +++ +LL | let ptr = &raw mut val; + | ~~~ error: aborting due to 1 previous error ```
…=compiler-errors AIX: add alignment info for test Supply alignment and size info for test cases for AIX.
…mpiler-errors Fix some comments related to upvars handling I'm tidying up my ergonomic ref counting PR and I'm going to make some small, simple and unrelated changes outside that PR, so the main PR sticks more straight to the point.
…ng, r=jieyouxu Fix `-Z input-stats` ordering It currently depends on the hash algorithm. r? `@Noratrieb`
…ouxu bootstrap: fix a comment I don't actually know if this is right, though... but "a single call to `paths` will only ever generate a single call to `paths`" just does not make sense.
…ackh726 small borrowck cleanup the already approved parts of rust-lang#133909 and rust-lang#133961 r? `@jackh726`
@bors r+ rollup=never p=5 |
☀️ Test successful - checks-actions |
📌 Perf builds for each rolled up PR:
previous master: 604d6691d9 In the case of a perf regression, run the following command for each PR you suspect might be the cause: |
Finished benchmarking commit (f23a80a): comparison URL. Overall result: no relevant changes - no action needed@rustbot label: -perf-regression Instruction countThis benchmark run did not return any relevant results for this metric. Max RSS (memory usage)Results (primary 3.8%, secondary 1.1%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResults (secondary -2.9%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 768.397s -> 770.185s (0.23%) |
Successful merges:
rustc::existing_doc_keyword
lint #134202 (Removerustc::existing_doc_keyword
lint)rustc_mir_build::build
tobuilder
#134365 (Renamerustc_mir_build::build
tobuilder
)&raw const
to&raw mut
if applicable #134397 (rustc_borrowck: Suggest changing&raw const
to&raw mut
if applicable)-Z input-stats
ordering #134406 (Fix-Z input-stats
ordering)r? @ghost
@rustbot modify labels: rollup
Create a similar rollup