commit | 0f8e46f63aac7f9666e74bcf52e1c9daa8e9c508 | [log] [tgz] |
---|---|---|
author | Android Build Coastguard Worker <[email protected]> | Wed Apr 17 23:12:43 2024 +0000 |
committer | Android Build Coastguard Worker <[email protected]> | Wed Apr 17 23:12:43 2024 +0000 |
tree | 5da872d46a1e7a00ed4b39bff28fa89c4d4fe1f2 | |
parent | ecaa3b6aef58d5143730c0c518fd2f734732af19 [diff] | |
parent | e10f9a6523c263e9bbd2f5af1094200311434f5d [diff] |
Snap for 11728787 from e10f9a6523c263e9bbd2f5af1094200311434f5d to 24Q3-release Change-Id: I34358e527fb3518e7c81a1e506be8fd43e1af777
Chrono aims to provide all functionality needed to do correct operations on dates and times in the proleptic Gregorian calendar:
DateTime
type is timezone-aware by default, with separate timezone-naive types.Option
or LocalResult
.strftime
inspired date and time formatting syntax.Local
timezone works with the current timezone of the OS.Timezone data is not shipped with chrono by default to limit binary sizes. Use the companion crate Chrono-TZ or tzfile
for full timezone support.
See docs.rs for the API reference.
Default features:
alloc
: Enable features that depend on allocation (primarily string formatting)std
: Enables functionality that depends on the standard library. This is a superset of alloc
and adds interoperation with standard library types and traits.clock
: Enables reading the local timezone (Local
). This is a superset of now
.now
: Enables reading the system time (now
)wasmbind
: Interface with the JS Date API for the wasm32
target.Optional features:
serde
: Enable serialization/deserialization via serde.rkyv
: Enable serialization/deserialization via rkyv.rustc-serialize
: Enable serialization/deserialization via rustc-serialize (deprecated).arbitrary
: construct arbitrary instances of a type with the Arbitrary crate.unstable-locales
: Enable localization. This adds various methods with a _localized
suffix. The implementation and API may change or even be removed in a patch release. Feedback welcome.The Minimum Supported Rust Version (MSRV) is currently Rust 1.61.0.
The MSRV is explicitly tested in CI. It may be bumped in minor releases, but this is not done lightly.
This project is licensed under either of
at your option.