Mark `FixedOffset::{local_minus_utc, utc_minus_local}` as `#[inline]`.

This commit is contained in:
kennytm 2019-04-22 03:07:01 +08:00
parent 7bc2cd8641
commit 20a0ab7a47
No known key found for this signature in database
GPG Key ID: FEF6C8051D0E013C
1 changed files with 2 additions and 0 deletions

View File

@ -86,11 +86,13 @@ impl FixedOffset {
}
/// Returns the number of seconds to add to convert from UTC to the local time.
#[inline]
pub fn local_minus_utc(&self) -> i32 {
self.local_minus_utc
}
/// Returns the number of seconds to add to convert from the local time to UTC.
#[inline]
pub fn utc_minus_local(&self) -> i32 {
-self.local_minus_utc
}