about summary refs log tree commit diff
diff options
context:
space:
mode:
authorJon Gjengset <jon@thesquareplanet.com>2020-05-30 15:20:09 -0400
committerJon Gjengset <jon@thesquareplanet.com>2020-06-20 10:53:39 -0400
commitad7fd6265e62b2170612544caea3b8454ebb3fed (patch)
tree67cfaf77200d8b6f9fb124ae30beaa2c10cfd2ae
parent3ff5879f8d50da4807c639a17df5884bcaa8b319 (diff)
downloadrust-ad7fd6265e62b2170612544caea3b8454ebb3fed.tar.gz
rust-ad7fd6265e62b2170612544caea3b8454ebb3fed.zip
Doctests need feature
-rw-r--r--src/libcore/time.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/libcore/time.rs b/src/libcore/time.rs
index cf88ff2e10f..d94f2378058 100644
--- a/src/libcore/time.rs
+++ b/src/libcore/time.rs
@@ -228,6 +228,7 @@ impl Duration {
     /// # Examples
     ///
     /// ```
+    /// #![feature(duration_zero)]
     /// use std::time::Duration;
     ///
     /// let duration = Duration::zero();
@@ -247,6 +248,7 @@ impl Duration {
     /// # Examples
     ///
     /// ```
+    /// #![feature(duration_zero)]
     /// use std::time::Duration;
     ///
     /// assert!(Duration::zero().is_zero());