Skip to content

Commit 0eba00b

Browse files
authored
Update lib.rs (#75)
For ergonomic reasons a default implementation for `DateTime` is useful and all zero's and false is fine, though some specific other value may be more suitable
1 parent 0baffdd commit 0eba00b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -505,7 +505,7 @@ pub struct ContentType<'x> {
505505
}
506506

507507
/// An RFC5322 datetime.
508-
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
508+
#[derive(Clone, Copy, Debug, PartialEq, Eq, Default)]
509509
#[cfg_attr(feature = "serde_support", derive(Serialize, Deserialize))]
510510
pub struct DateTime {
511511
pub year: u16,

0 commit comments

Comments
 (0)