From 376837b999dc4a6ec271080957cd46b59bb5cc32 Mon Sep 17 00:00:00 2001 From: Romain Porte Date: Sat, 9 Sep 2017 11:46:58 +0200 Subject: [PATCH] from_micros: Inlined return for consistency --- src/libstd/time/duration.rs | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/libstd/time/duration.rs b/src/libstd/time/duration.rs index 8c37c38bbc8f..43cc2b880f7a 100644 --- a/src/libstd/time/duration.rs +++ b/src/libstd/time/duration.rs @@ -133,10 +133,7 @@ impl Duration { pub fn from_micros(micros: u64) -> Duration { let secs = micros / MICROS_PER_SEC; let nanos = ((micros % MICROS_PER_SEC) as u32) * NANOS_PER_MICRO; - Duration { - secs: secs, - nanos: nanos, - } + Duration { secs: secs, nanos: nanos } } /// Returns the number of _whole_ seconds contained by this `Duration`.