rust/tests/ui/new_without_default.stderr
2018-10-06 09:43:08 -07:00

41 lines
1.0 KiB
Plaintext

error: you should consider deriving a `Default` implementation for `Foo`
--> $DIR/new_without_default.rs:22:5
|
22 | pub fn new() -> Foo { Foo }
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: `-D clippy::new-without-default-derive` implied by `-D warnings`
help: try this
|
19 | #[derive(Default)]
|
error: you should consider deriving a `Default` implementation for `Bar`
--> $DIR/new_without_default.rs:28:5
|
28 | pub fn new() -> Self { Bar }
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
help: try this
|
25 | #[derive(Default)]
|
error: you should consider adding a `Default` implementation for `LtKo<'c>`
--> $DIR/new_without_default.rs:76:5
|
76 | pub fn new() -> LtKo<'c> { unimplemented!() }
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: `-D clippy::new-without-default` implied by `-D warnings`
help: try this
|
75 | impl Default for LtKo<'c> {
76 | fn default() -> Self {
77 | Self::new()
78 | }
79 | }
|
error: aborting due to 3 previous errors