Format PR 1702 with rustfmt

This commit is contained in:
David Tolnay 2020-05-09 18:24:05 -07:00
parent a81968af3c
commit 3c97e1b9a9
No known key found for this signature in database
GPG Key ID: F9BA143B95FF6D82

View File

@ -616,7 +616,7 @@ impl Serialize for SystemTime {
use super::SerializeStruct;
let duration_since_epoch = self
.duration_since(UNIX_EPOCH)
.map_err(|_|S::Error::custom("SystemTime must be later than UNIX_EPOCH"))?;
.map_err(|_| S::Error::custom("SystemTime must be later than UNIX_EPOCH"))?;
let mut state = try!(serializer.serialize_struct("SystemTime", 2));
try!(state.serialize_field("secs_since_epoch", &duration_since_epoch.as_secs()));
try!(state.serialize_field("nanos_since_epoch", &duration_since_epoch.subsec_nanos()));