-
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
Reject ?Trait
bounds in various places where we unconditionally warned since 1.0
#135841
base: master
Are you sure you want to change the base?
Conversation
rustbot has assigned @compiler-errors. Use |
HIR ty lowering was modified cc @fmease |
@bors try |
Reject `impl Trait` within `?Trait` generics or assoc ty bounds fixes rust-lang#135730 Also a breaking change, so let's see what crater says. This has been an unconditional warning since *before* 1.0
This comment has been minimized.
This comment has been minimized.
☀️ Try build successful - checks-actions |
@craterbot check |
👌 Experiment ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more |
🚧 Experiment ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more |
🎉 Experiment
|
impl Trait
within ?Trait
generics or assoc ty bounds?Trait
bounds in various places where we unconditionally warned since 1.0
… warned since 1.0
757c75f
to
4e7c9e6
Compare
Hi @rust-lang/types, it turns out we've accepted One common source of problems with such bounds is that they can have generics or associated types/consts and all of these just get dropped on the floor and never evaluated, normalized, or otherwise processed in the type system. This leads to fun bugs like not evaluating constants or just ICEing because opaque types never got defined. @rfcbot fcp merge |
Team member @oli-obk has proposed to merge this. The next step is review by the rest of the tagged team members: No concerns currently listed. Once a majority of reviewers approve (and at most 2 approvals are outstanding), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up! See this document for info about what commands tagged team members can give me. |
cc @rust-lang/lang for info I think this is fine as a pure types team FCP. Allowing these bounds is causing bugs without any benefit. |
@rfcbot reviewed |
🔔 This is now entering its final comment period, as per the review above. 🔔 |
fixes #135730
fixes #135809
Also a breaking change, so let's see what crater says.
This has been an unconditional warning since before 1.0