refactor: clippy::default_trait_access (#974)

This commit is contained in:
EdJoPaTo 2024-02-27 13:38:57 +01:00 committed by Josh McKinney
parent 8536760e78
commit 01418eb7c2
No known key found for this signature in database
GPG Key ID: 722287396A903BC5
2 changed files with 10 additions and 9 deletions

View File

@ -65,6 +65,7 @@ serde_json = "1.0.109"
unsafe_code = "forbid" unsafe_code = "forbid"
[lints.clippy] [lints.clippy]
cloned_instead_of_copied = "warn" cloned_instead_of_copied = "warn"
default_trait_access = "warn"
explicit_iter_loop = "warn" explicit_iter_loop = "warn"
implicit_clone = "warn" implicit_clone = "warn"
inefficient_to_string = "warn" inefficient_to_string = "warn"

View File

@ -223,16 +223,16 @@ pub struct Table<'a> {
impl<'a> Default for Table<'a> { impl<'a> Default for Table<'a> {
fn default() -> Self { fn default() -> Self {
Self { Self {
rows: Default::default(), rows: Vec::new(),
header: Default::default(), header: None,
footer: Default::default(), footer: None,
widths: Default::default(), widths: Vec::new(),
column_spacing: 1, column_spacing: 1,
block: Default::default(), block: None,
style: Default::default(), style: Style::new(),
highlight_style: Default::default(), highlight_style: Style::new(),
highlight_symbol: Default::default(), highlight_symbol: Text::default(),
highlight_spacing: Default::default(), highlight_spacing: HighlightSpacing::default(),
flex: Flex::Start, flex: Flex::Start,
} }
} }