Expand where negative supertrait specific error is shown

Fix #58857.
This commit is contained in:
Esteban Küber 2019-03-01 14:42:39 -08:00
parent c1d2d83ca3
commit dc4973dfd9
3 changed files with 41 additions and 22 deletions

View file

@ -0,0 +1,7 @@
struct Conj<A> {a : A}
trait Valid {}
impl<A: !Valid> Conj<A>{}
//~^ ERROR negative trait bounds are not supported
fn main() {}

View file

@ -0,0 +1,8 @@
error: negative trait bounds are not supported
--> $DIR/issue-58857.rs:4:7
|
LL | impl<A: !Valid> Conj<A>{}
| ^^^^^^^^ help: remove the trait bound
error: aborting due to previous error