Skip to content

Commit d926950

Browse files
committed
better docs per review suggestion
1 parent 706a961 commit d926950

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

clippy_lints/src/new_without_default.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,8 +85,9 @@ declare_clippy_lint! {
8585
/// }
8686
/// ```
8787
///
88-
/// Alternatively, if the `new()` method requires a non-default initialization, implement a custom `Default`.
89-
/// This also allows you to mark the `new()` implementation as `const`:
88+
/// Alternatively, if the `new()` method requires a non-default initialization, consider renaming
89+
/// it to another less standard name. Lastly, if the `new()` method needs to be `const`,
90+
/// implement a custom `Default`:
9091
///
9192
/// ```no_run
9293
/// struct MyStruct(i32);

0 commit comments

Comments
 (0)