chronos: A high-performance time library
Chronos is a performance-oriented time library for Haskell, with a straightforward API. The main differences between this and the time library are:
Chronos uses machine integers where possible. This means that time-related arithmetic should be faster, with the drawback that the types are incapable of representing times that are very far in the future or the past (because Chronos provides nanosecond, rather than picosecond, resolution). For most users, this is not a hindrance.
Chronos provides
ToJSON
/FromJSON
instances for serialisation.Chronos provides
Unbox
instances for working with unboxed vectors.Chronos provides
Prim
instances for working with byte arrays/primitive arrays.Chronos uses normal non-overloaded haskell functions for encoding and decoding time. It provides attoparsec parsers for both
Text
andByteString
. Additionally, Chronos provides functions for encoding time toText
orByteString
. The http://hackage.haskell.org/package/time time> library accomplishes these with the Data.Time.Format module, which uses UNIX-style datetime format strings. The approach taken by Chronos is faster and catches more mistakes at compile time, at the cost of being less expressive.
Downloads
- chronos-1.1.4.tar.gz [browse] (Cabal source package)
- Package description (revised from the package)
Note: This package has metadata revisions in the cabal description newer than included in the tarball. To unpack the package including the revisions, use 'cabal get'.
Maintainer's Corner
For package maintainers and hackage trustees
Candidates
Versions [RSS] | 0.1.0, 0.2.0, 0.3, 0.4, 1.0, 1.0.1, 1.0.2, 1.0.3, 1.0.4, 1.0.5, 1.0.6, 1.0.7, 1.0.8, 1.0.9, 1.1, 1.1.1, 1.1.2, 1.1.3, 1.1.4, 1.1.5, 1.1.5.1, 1.1.6.0, 1.1.6.1, 1.1.6.2 |
---|---|
Dependencies | aeson (>=1.1 && <2.2), attoparsec (>=0.13 && <0.15), base (>=4.14 && <4.17), bytebuild (>=0.3.8 && <0.4), byteslice (>=0.2.5.2 && <0.3), bytesmith (>=0.3.7 && <0.4), bytestring (>=0.10 && <0.12), deepseq (>=1.4.4.0), hashable (>=1.2 && <1.5), natural-arithmetic (>=0.1.2 && <0.2), primitive (>=0.6.4 && <0.8), semigroups (>=0.16 && <0.20), text (>=1.2 && <1.3), text-short (>=0.1.3 && <0.2), torsor (>=0.1 && <0.2), vector (>=0.11 && <0.13), Win32 (>=2.2 && <2.14) [details] |
License | BSD-3-Clause |
Copyright | 2016 Andrew Martin |
Author | Andrew Martin |
Maintainer | Andrew Martin <andrew.thaddeus@gmail.com> chessai <chessai1996@gmail.com> |
Revised | Revision 2 made by andrewthad at 2022-07-26T16:49:08Z |
Category | Data, Time, Parsing, Development |
Home page | https://github.com/andrewthad/chronos |
Source repo | head: git clone https://github.com/andrewthad/chronos |
Uploaded | by andrewthad at 2022-02-21T14:03:07Z |
Distributions | LTSHaskell:1.1.6.2, NixOS:1.1.6.1 |
Reverse Dependencies | 26 direct, 29 indirect [details] |
Downloads | 14688 total (95 in the last 30 days) |
Rating | 2.0 (votes: 1) [estimated by Bayesian average] |
Your Rating | |
Status | Docs available [build log] Last success reported on 2022-02-21 [all 1 reports] |