Improve selection errors for ~const trait bounds#92256
Improve selection errors for ~const trait bounds#92256bors merged 2 commits intorust-lang:masterfrom
~const trait bounds#92256Conversation
|
(rust-highfive has picked a reviewer for you, use r? to override) |
|
r? @oli-obk |
There was a problem hiding this comment.
Would it be possible to keep the previous message and just append in const contexts. The trait bound message appears again below anyway, so that would seem easier to read by humans
There was a problem hiding this comment.
The way to approach this might be adding a flag to the rustc_on_unimplemented directive that allows appending in const contexts instead of falling back to the generic message.
There was a problem hiding this comment.
Hmm.. I was hoping we could patch rustc_on_unimplemented to just append this, but I forgot that the messages are entirely custom and could make the wording weird or nonsensical.
So... a required field for rustc_on_unimplemented with an append snippet or just an entirely new message?
compiler/rustc_trait_selection/src/traits/error_reporting/mod.rs
Outdated
Show resolved
Hide resolved
2c8dbe0 to
6fe7ae6
Compare
This comment has been minimized.
This comment has been minimized.
6fe7ae6 to
f4522db
Compare
|
Good enough for now ^^ r=me with the Option::filter nit |
This comment has been minimized.
This comment has been minimized.
|
☔ The latest upstream changes (presumably #93173) made this pull request unmergeable. Please resolve the merge conflicts. |
f4522db to
8b76cad
Compare
|
That nit is obsolete when you made that comment. Feel free to r- and review it again. @bors r=oli-obk |
|
📌 Commit 8b76cad has been approved by |
…askrgr Rollup of 7 pull requests Successful merges: - rust-lang#90247 (Improve Duration::try_from_secs_f32/64 accuracy by directly processing exponent and mantissa) - rust-lang#91861 (Replace iterator-based construction of collections by `Into<T>`) - rust-lang#92098 (add OpenBSD platform-support page) - rust-lang#92134 (Add x86_64-pc-windows-msvc linker-plugin-lto instructions) - rust-lang#92256 (Improve selection errors for `~const` trait bounds) - rust-lang#92778 (fs: Use readdir() instead of readdir_r() on Linux and Android) - rust-lang#93338 (Update minifier crate version to 0.0.42) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
No description provided.