From cb9fd7fbe1f5ceea690bbdd4777c6f8147783eaa Mon Sep 17 00:00:00 2001 From: Kang Seonghoon Date: Thu, 4 Aug 2016 03:44:31 +0900 Subject: [PATCH] 0.2.25: Fixed warnings from 0.2.24. Duh. --- CHANGELOG.md | 5 ++++- Cargo.toml | 2 +- README.md | 2 +- src/lib.rs | 2 +- src/naive/date.rs | 2 ++ src/naive/time.rs | 2 ++ src/offset/fixed.rs | 2 ++ 7 files changed, 13 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index edde79e..6768b12 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,7 +8,10 @@ Chrono obeys the principle of [Semantic Versioning](http://semver.org/). There were/are numerous minor versions before 1.0 due to the language changes. Versions with only mechnical changes will be omitted from the following list. -## 0.2.24 (2016-08-04) +## 0.2.25 (2016-08-04) + +(0.2.24 was accidentally uploaded without a proper check for warnings in the default state, +and replaced by 0.2.25 very shortly. Duh.) ### Added diff --git a/Cargo.toml b/Cargo.toml index 24d3bfd..3feecf2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "chrono" -version = "0.2.24" +version = "0.2.25" authors = ["Kang Seonghoon "] description = "Date and time library for Rust" diff --git a/README.md b/README.md index acf9701..0d503a2 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -[Chrono][doc] 0.2.24 +[Chrono][doc] 0.2.25 ==================== [![Chrono on Travis CI][travis-image]][travis] diff --git a/src/lib.rs b/src/lib.rs index 49b8781..68f390f 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -2,7 +2,7 @@ // Copyright (c) 2014-2015, Kang Seonghoon. // See README.md and LICENSE.txt for details. -//! # Chrono 0.2.24 +//! # Chrono 0.2.25 //! //! Date and time handling for Rust. (also known as `rust-chrono`) //! It aims to be a feature-complete superset of diff --git a/src/naive/date.rs b/src/naive/date.rs index b308321..06f629b 100644 --- a/src/naive/date.rs +++ b/src/naive/date.rs @@ -129,6 +129,7 @@ impl NaiveDate { /// Makes a new `NaiveDate` from the serialized representation. /// Used for serialization formats. + #[cfg(feature = "rustc-serialize")] fn from_serialized(ymdf: i32) -> Option { // check if the year flag is correct if (ymdf & 0b1111) as u8 != YearFlags::from_year(ymdf >> 13).0 { return None; } @@ -141,6 +142,7 @@ impl NaiveDate { } /// Returns a serialized representation of this `NaiveDate`. + #[cfg(feature = "rustc-serialize")] fn to_serialized(&self) -> i32 { self.ymdf } diff --git a/src/naive/time.rs b/src/naive/time.rs index fc85db2..9b5524b 100644 --- a/src/naive/time.rs +++ b/src/naive/time.rs @@ -66,6 +66,7 @@ pub struct NaiveTime { impl NaiveTime { /// Makes a new `NaiveTime` from the serialized representation. /// Used for serialization formats. + #[cfg(feature = "rustc-serialize")] fn from_serialized(secs: u32, frac: u32) -> Option { // check if the values are in the range if secs >= 86400 { return None; } @@ -76,6 +77,7 @@ impl NaiveTime { } /// Returns a serialized representation of this `NaiveDate`. + #[cfg(feature = "rustc-serialize")] fn to_serialized(&self) -> (u32, u32) { (self.secs, self.frac) } diff --git a/src/offset/fixed.rs b/src/offset/fixed.rs index eba3bea..c9471c3 100644 --- a/src/offset/fixed.rs +++ b/src/offset/fixed.rs @@ -23,6 +23,7 @@ pub struct FixedOffset { impl FixedOffset { /// Makes a new `FixedOffset` from the serialized representation. /// Used for serialization formats. + #[cfg(feature = "rustc-serialize")] fn from_serialized(secs: i32) -> Option { // check if the values are in the range if secs <= -86400 || 86400 <= secs { return None; } @@ -32,6 +33,7 @@ impl FixedOffset { } /// Returns a serialized representation of this `FixedOffset`. + #[cfg(feature = "rustc-serialize")] fn to_serialized(&self) -> i32 { self.local_minus_utc }