use shorthand in a fmt string

This commit is contained in:
Maybe Waffle 2023-02-21 18:45:33 +04:00
parent 846e0819de
commit bec3522eae

View file

@ -4,7 +4,7 @@ use serde::{Deserialize, Serialize};
#[derive(Clone, Copy)] #[derive(Clone, Copy)]
#[derive(PartialEq, Eq, PartialOrd, Ord, Hash)] #[derive(PartialEq, Eq, PartialOrd, Ord, Hash)]
#[derive(Debug, derive_more::Display)] #[derive(Debug, derive_more::Display)]
#[display(fmt = "{}s", _0)] #[display(fmt = "{_0}s")]
#[derive(Serialize, Deserialize)] #[derive(Serialize, Deserialize)]
#[serde(transparent)] #[serde(transparent)]
pub struct Seconds(u32); pub struct Seconds(u32);