This library is no longer actively maintained, but bugfixes will be added (details).
In case you're looking for something a little fresher and more actively maintained have a look at the chrono
crate.
Put this in your Cargo.toml
:
[dependencies] time = "0.1"
And this in your crate root:
extern crate time;