-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Bounds seem to be ignored in negative impls #23072
Comments
Yeah, hmm, this is caused by the way that trait dispatch picks a concrete impl if its the only thing available without recursively evaluating the bounds. Hmm. It makes sense for positive impls but for negative impls doesn't seem quite right. Niko -------- Original message -------- #![feature(optin_builtin_traits)] use std::marker::MarkerTrait; unsafe trait Pod: MarkerTrait {} trait Bound: MarkerTrait {} // it seems that the bound is ignored here, i.e. this gets treated as fn is_pod<T: Pod>(_: T) {} fn main() { — |
This turns out to be a deeper issue. We should hold off on removing feature-gate for negative impls until it is resolved. The core issue that that negative impls with extra bounds become effectively negative bounds:
Now |
error still persist in
|
triage: OIBITs cannot have bounds anymore. yay. |
cc @nikomatsakis @flaper87
The text was updated successfully, but these errors were encountered: