mirror of
https://github.com/Xevion/exercism.git
synced 2025-12-15 02:11:44 -06:00
11 lines
281 B
Rust
11 lines
281 B
Rust
use std::time::SystemTime;
|
|
|
|
use time::PrimitiveDateTime as DateTime;
|
|
|
|
const GIGASECOND_IN_SECONDS: i64 = 1_000_000_000;
|
|
|
|
// Returns a DateTime one billion seconds after start.
|
|
pub fn after(start: DateTime) -> DateTime {
|
|
start + time::Duration::seconds(GIGASECOND_IN_SECONDS)
|
|
}
|