Skip to content

Commit de97c6f

Browse files
committed
style: Make clippy happy
1 parent 0545b97 commit de97c6f

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

crates/colorchoice/src/lib.rs

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,10 @@ use core::sync::atomic::{AtomicUsize, Ordering};
1010

1111
/// Selection for overriding color output
1212
#[allow(clippy::exhaustive_enums)]
13-
#[derive(Copy, Clone, Debug, PartialEq, Eq)]
13+
#[derive(Copy, Clone, Debug, PartialEq, Eq, Default)]
1414
pub enum ColorChoice {
1515
/// Use colors if the output device appears to support them
16+
#[default]
1617
Auto,
1718
/// Like `Always`, except it never tries to use anything other than emitting ANSI
1819
/// color codes.
@@ -37,12 +38,6 @@ impl ColorChoice {
3738
}
3839
}
3940

40-
impl Default for ColorChoice {
41-
fn default() -> Self {
42-
Self::Auto
43-
}
44-
}
45-
4641
static USER: AtomicChoice = AtomicChoice::new();
4742

4843
#[derive(Debug)]

0 commit comments

Comments
 (0)