Auto merge of #58872 - rep-nop:diagnostic-fix-56031, r=petrochenkov

Adds help message in error for invalid `impl for T` syntax

Fixes #56031.
This commit is contained in:
bors 2019-03-18 08:03:05 +00:00
commit cd45b19bd2
3 changed files with 25 additions and 3 deletions

View file

@ -0,0 +1,6 @@
struct T;
impl for T {}
//~^ ERROR missing trait in a trait impl
fn main() {}

View file

@ -0,0 +1,8 @@
error: missing trait in a trait impl
--> $DIR/issue-56031.rs:3:5
|
LL | impl for T {}
| ^
error: aborting due to previous error