]> git.lizzy.rs Git - rust.git/blob - tests/ui/new_without_default.stderr
Auto merge of #3587 - flip1995:ui-testing, r=phansch
[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 LL | /     pub fn new() -> Foo {
5 LL | |         Foo
6 LL | |     }
7    | |_____^
8    |
9    = note: `-D clippy::new-without-default-derive` implied by `-D warnings`
10 help: try this
11    |
12 LL | #[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 LL | /     pub fn new() -> Self {
19 LL | |         Bar
20 LL | |     }
21    | |_____^
22 help: try this
23    |
24 LL | #[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 LL | /     pub fn new() -> LtKo<'c> {
31 LL | |         unimplemented!()
32 LL | |     }
33    | |_____^
34    |
35    = note: `-D clippy::new-without-default` implied by `-D warnings`
36 help: try this
37    |
38 LL | impl Default for LtKo<'c> {
39 LL |     fn default() -> Self {
40 LL |         Self::new()
41 LL |     }
42 LL | }
43    |
44
45 error: aborting due to 3 previous errors
46