cleanup: derive Default where possible

Not doing so triggers a clippy lint on Rust >= 1.91.

Part of #12013
This commit is contained in:
Daniel Rainer
2025-10-31 17:52:19 +01:00
committed by Johannes Altmanninger
parent f511ef69c3
commit 6422139fe0
2 changed files with 2 additions and 3 deletions

View File

@@ -3,7 +3,7 @@
// Implementation of the block builtin.
use super::prelude::*;
#[derive(Debug, Clone, Copy, PartialEq, Eq, Default)]
#[derive(Clone, Copy, Debug, Default, PartialEq, Eq)]
enum Scope {
#[default]
Unset,

View File

@@ -1213,9 +1213,8 @@ fn get_fallback(role: HighlightRole) -> HighlightRole {
}
/// Describes the role of a span of text.
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[derive(Clone, Copy, Debug, Default, Eq, Hash, PartialEq)]
#[repr(u8)]
#[derive(Default)]
pub enum HighlightRole {
#[default]
normal, // normal text