Repository navigation
Rollup of 6 pull requests - #165829
Open
JonathanBrouwer wants to merge 16 commits into
Open
Rollup of 6 pull requests#165829JonathanBrouwer wants to merge 16 commits into
JonathanBrouwer wants to merge 16 commits into
Conversation
This pulls some less-trivial changes out of the main migration to `Value<'ll>`.
derived impls kept the lifetime spans of the derive input so the external macro check missed them and `#[expect(redundant_lifetimes)]` on a derived struct went unfulfilled. the lint now skips items whose own span is in an external macro.
Just because the parser of a specific syntax fragment kind returns an `Err(_)` doesn't automatically mean that the problematic token sequence isn't "of" that fragment's kind. The token sequence might "almost" be of that kind (i.e., share a non-empty prefix) but simply contain a syntax error in it. On a side note, it's rather odd that the now removed `annotate_err_with_kind` only added the note "this macro call doesn't expand to a $fragkind" if the target fragment kind was *type* or *pat*, there are 20 kinds at the of writing.
…..)` This also means that it's now available under `core::pat` instead of `core` directly. This makes it consistent with the `std` re-export which is only available under `std::pat` and not under `std` directly. Moreover, drop library feature `pattern_type_macro` and demote language feature `pattern_types` to a library feature. This is nice because it means `std::pat::pattern_type` is no longer unnecessarily gated behind two (!) feature gates.
This also means that it's now available under `core::view` instead of `core` directly. This makes it consistent with the `std` re-export which is only available under `std::view` and not under `std` directly. Moreover, drop library feature `view_type_macro` and demote language feature `view_types` to a library feature. This is nice because it means `std::view::view_type` is no longer unnecessarily gated behind two (!) feature gates.
cg_llvm: Use an invariant lifetime brand for LLVM values This PR changes the type of LLVM value references from `&'ll Value` to `Value<'ll>` with an invariant lifetime brand, to help uphold soundness of the FFI bindings. There should be no change to compiler output. --- Value is one of the more widely-used types, much more so than Type, so unfortunately this step ends up needing to touch quite a lot of code. Thankfully almost all of the changes are trivial.
Implement `core::ops::FnAddr` This implements `FnAddr` as proposed in rust-lang/libs-team#837 (comment). This is my first contribution to the rust compiler, so I'm not 100% familiar with the process. All code was hand written by me. cc rust-lang#148768
…syntax, r=mati865 Migrate built-in macros `pattern_type` & `view_type` to macros 2.0 that expand to internal syntax Part of MCP-approved rust-lang#110680. Best reviewed commit by commit. Please see individual commit messages for further details. Pinging owner of pattern types @oli-obk & owner of view types @scrabsha for visibility. <sub>(No LLM was or will be used by me during the entire creation process of this PR)</sub>
…ternal-macro, r=petrochenkov do not lint `redundant_lifetimes` on items from external macros derived impls copy the lifetime spans from the derive input so the external macro check on the lint span never fires and the lint is reported on the generated impl. that also left `#[expect(redundant_lifetimes)]` on a derived struct unfulfillable. now the lint skips items whose own span is in an external macro. fixes rust-lang#150553 as suggested in rust-lang#150553 (comment) r? @petrochenkov
Extend support of lint `explicit_outlives_requirements` to checked type aliases Best reviewed by ignoring whitespace changes. Part of rust-lang#112792. <sub>(No LLM was or will be used by me during the entire creation process of this PR)</sub>
…=aerooneqq Add regression test for HRTB projection bound with TryFrom error Fixes rust-lang#81162 This was fixed by rust-lang#85499.
Member
Author
Contributor
rust-bors Bot
pushed a commit
that referenced
this pull request
Nov 11, 2026
Rollup of 6 pull requests try-job: dist-various-1 try-job: test-various try-job: test-x86_64-gnu-aux try-job: test-x86_64-msvc-1 try-job: test-aarch64-apple-1 try-job: test-aarch64-apple-2 try-job: test-x86_64-mingw-1 try-job: test-i686-msvc try-job: test-armhf-gnu try-job: test-x86_64-gnu-llvm-22-3 try-job: test-aarch64-msvc-2
This comment has been minimized.
This comment has been minimized.
Contributor
This comment has been minimized.
This comment has been minimized.
rust-bors Bot
pushed a commit
that referenced
this pull request
Nov 12, 2026
…uwer Rollup of 6 pull requests Successful merges: - #165804 (cg_llvm: Use an invariant lifetime brand for LLVM values) - #165412 (Implement `core::ops::FnAddr`) - #165487 (Migrate built-in macros `pattern_type` & `view_type` to macros 2.0 that expand to internal syntax) - #165818 (do not lint `redundant_lifetimes` on items from external macros) - #164795 (Extend support of lint `explicit_outlives_requirements` to checked type aliases) - #165824 (Add regression test for HRTB projection bound with TryFrom error)
Contributor
|
💔 Test for 9190e47 failed: CI. Failed job:
|
Collaborator
|
The job Click to see the possible cause of the failure (guessed by this bot) |
This branch has not been deployed
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.
Successful merges:
core::ops::FnAddr#165412 (Implementcore::ops::FnAddr)pattern_type&view_typeto macros 2.0 that expand to internal syntax #165487 (Migrate built-in macrospattern_type&view_typeto macros 2.0 that expand to internal syntax)redundant_lifetimeson items from external macros #165818 (do not lintredundant_lifetimeson items from external macros)explicit_outlives_requirementsto checked type aliases #164795 (Extend support of lintexplicit_outlives_requirementsto checked type aliases)r? @ghost
Create a similar rollup