This commit is contained in:
Wilco Kusee 2019-01-07 14:38:01 +01:00
parent 351688db78
commit 466cd076a2
No known key found for this signature in database
GPG key ID: D5B2BB5CDC3334BC
2 changed files with 2 additions and 4 deletions

View file

@ -253,9 +253,7 @@ mod nesting {
impl Bar {
fn bar() -> Bar {
Bar {
foo: Foo{},
}
Bar { foo: Foo {} }
}
}
}

View file

@ -159,7 +159,7 @@ LL | fn bar() -> Bar {
error: unnecessary structure name repetition
--> $DIR/use_self.rs:256:21
|
LL | Bar {
LL | Bar { foo: Foo {} }
| ^^^ help: use the applicable keyword: `Self`
error: aborting due to 26 previous errors