permit negative impls for non-auto traits
This commit is contained in:
parent
a17dd36084
commit
e8a05e201e
35 changed files with 328 additions and 101 deletions
|
|
@ -1,12 +0,0 @@
|
|||
#![feature(optin_builtin_traits)]
|
||||
|
||||
trait Trait {
|
||||
type Bar;
|
||||
}
|
||||
|
||||
struct Foo;
|
||||
|
||||
impl !Trait for Foo { } //~ ERROR E0192
|
||||
|
||||
fn main() {
|
||||
}
|
||||
|
|
@ -1,11 +0,0 @@
|
|||
error[E0192]: invalid negative impl
|
||||
--> $DIR/E0192.rs:9:6
|
||||
|
|
||||
LL | impl !Trait for Foo { }
|
||||
| ^^^^^^
|
||||
|
|
||||
= note: negative impls are only allowed for auto traits, like `Send` and `Sync`
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
For more information about this error, try `rustc --explain E0192`.
|
||||
Loading…
Add table
Add a link
Reference in a new issue