]> git.lizzy.rs Git - rust.git/blob - tests/ui/new_without_default.stderr
Merge branch 'master' into rustfmt_tests
[rust.git] / tests / ui / new_without_default.stderr
1 error: you should consider deriving a `Default` implementation for `Foo`
2   --> $DIR/new_without_default.rs:17:5
3    |
4 17 | /     pub fn new() -> Foo {
5 18 | |         Foo
6 19 | |     }
7    | |_____^
8    |
9    = note: `-D clippy::new-without-default-derive` implied by `-D warnings`
10 help: try this
11    |
12 14 | #[derive(Default)]
13    |
14
15 error: you should consider deriving a `Default` implementation for `Bar`
16   --> $DIR/new_without_default.rs:25:5
17    |
18 25 | /     pub fn new() -> Self {
19 26 | |         Bar
20 27 | |     }
21    | |_____^
22 help: try this
23    |
24 22 | #[derive(Default)]
25    |
26
27 error: you should consider adding a `Default` implementation for `LtKo<'c>`
28   --> $DIR/new_without_default.rs:89:5
29    |
30 89 | /     pub fn new() -> LtKo<'c> {
31 90 | |         unimplemented!()
32 91 | |     }
33    | |_____^
34    |
35    = note: `-D clippy::new-without-default` implied by `-D warnings`
36 help: try this
37    |
38 88 | impl Default for LtKo<'c> {
39 89 |     fn default() -> Self {
40 90 |         Self::new()
41 91 |     }
42 92 | }
43    |
44
45 error: aborting due to 3 previous errors
46