]> git.lizzy.rs Git - rust.git/blob - compiler/rustc_error_codes/src/error_codes/E0192.md
Auto merge of #91403 - cjgillot:inherit-async, r=oli-obk
[rust.git] / compiler / rustc_error_codes / src / error_codes / E0192.md
1 #### Note: this error code is no longer emitted by the compiler.
2
3 A negative impl was added on a trait implementation.
4
5 Erroneous code example:
6
7 ```compile_fail
8 trait Trait {
9     type Bar;
10 }
11
12 struct Foo;
13
14 impl !Trait for Foo { } //~ ERROR
15
16 fn main() {}
17 ```
18
19 Negative impls are only allowed for auto traits. For more
20 information see the [opt-in builtin traits RFC][RFC 19].
21
22 [RFC 19]: https://github.com/rust-lang/rfcs/blob/master/text/0019-opt-in-builtin-traits.md