Skip to content

Commit c6d24cd

Browse files
author
Stjepan Glavina
committed
Enable feature duration_constants in examples
1 parent f223c03 commit c6d24cd

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/libcore/time.rs

+4
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ impl Duration {
6464
/// # Examples
6565
///
6666
/// ```
67+
/// #![feature(duration_constants)]
6768
/// use std::time::Duration;
6869
///
6970
/// assert_eq!(Duration::SECOND, Duration::from_secs(1));
@@ -76,6 +77,7 @@ impl Duration {
7677
/// # Examples
7778
///
7879
/// ```
80+
/// #![feature(duration_constants)]
7981
/// use std::time::Duration;
8082
///
8183
/// assert_eq!(Duration::MILLISECOND, Duration::from_millis(1));
@@ -88,6 +90,7 @@ impl Duration {
8890
/// # Examples
8991
///
9092
/// ```
93+
/// #![feature(duration_constants)]
9194
/// use std::time::Duration;
9295
///
9396
/// assert_eq!(Duration::MICROSECOND, Duration::from_micros(1));
@@ -100,6 +103,7 @@ impl Duration {
100103
/// # Examples
101104
///
102105
/// ```
106+
/// #![feature(duration_constants)]
103107
/// use std::time::Duration;
104108
///
105109
/// assert_eq!(Duration::NANOSECOND, Duration::from_nanos(1));

0 commit comments

Comments
 (0)