Added underscores on long numbers.
This commit is contained in:
parent
532c025a77
commit
57c98a409e
|
@ -306,13 +306,14 @@
|
||||||
//! use chrono::TimeZone;
|
//! use chrono::TimeZone;
|
||||||
//!
|
//!
|
||||||
//! // Construct a datetime from epoch:
|
//! // Construct a datetime from epoch:
|
||||||
//! let dt = Utc.timestamp(1500000000, 0);
|
//! let dt = Utc.timestamp(1_500_000_000, 0);
|
||||||
//! assert_eq!(dt.to_rfc2822(), "Fri, 14 Jul 2017 02:40:00 +0000");
|
//! assert_eq!(dt.to_rfc2822(), "Fri, 14 Jul 2017 02:40:00 +0000");
|
||||||
//!
|
//!
|
||||||
//! // Get epoch value from a datetime:
|
//! // Get epoch value from a datetime:
|
||||||
//! let dt = DateTime::parse_from_rfc2822("Fri, 14 Jul 2017 02:40:00 +0000").unwrap();
|
//! let dt = DateTime::parse_from_rfc2822("Fri, 14 Jul 2017 02:40:00 +0000").unwrap();
|
||||||
//! assert_eq!(dt.timestamp(), 1500000000);
|
//! assert_eq!(dt.timestamp(), 1_500_000_000);
|
||||||
//! ```
|
//! ```
|
||||||
|
//!
|
||||||
//! ### Individual date
|
//! ### Individual date
|
||||||
//!
|
//!
|
||||||
//! Chrono also provides an individual date type ([**`Date`**](./struct.Date.html)).
|
//! Chrono also provides an individual date type ([**`Date`**](./struct.Date.html)).
|
||||||
|
|
Loading…
Reference in New Issue