LingMan
cd0e3b008c
chrono-fuzz: Update libfuzzer-sys dependency from 0.3 to 0.4
2023-03-03 11:42:39 +01:00
LingMan
d1043f39c8
Add chrono-fuzz to CI
...
Ensures future changes to break it again.
2023-03-03 11:42:39 +01:00
LingMan
90c7e55738
Run CI on changes to any file
...
Currently CI is only run on changes to specific files. The list of these files incomplete and would
likely get outdated again if it were expanded. Exluding specific files would be a shorter, more
stable list.
However, the changelog is only kept for posterity and the readme has seen all of two commits in the
past three years that wouldn't have triggered CI by changing other files as well, so don't bother
and just run CI for any changed file.
2023-03-03 11:42:39 +01:00
Bruce Guenter
cc64f84ac8
derive Hash
for most pub types that also derive PartialEq
2023-02-16 13:34:26 +01:00
Che
e63b7297c7
Add example of date conversion after 9999 CE
...
(cherry picked from commit 05b865deffff478facd737a540aa62d1f061acb6)
2023-02-16 10:32:29 +01:00
Che
64c4c0149d
Add (+/-) for consistency with strftime.rs
...
(cherry picked from commit a2fb1212f383e6ab59c0dec7854c173e8e63ef34)
2023-02-16 10:32:29 +01:00
c-git
366e7ea0c5
Add sign requirements for years to docs
...
(cherry picked from commit 7dfd8ca8e6b11c79a9035ba3b3ec03117e7999a9)
2023-02-16 10:32:29 +01:00
Dirkjan Ochtman
a892fcc7c2
Apply clippy suggestions for Rust 1.67
2023-02-02 09:34:54 +01:00
Kurtis Nusbaum
cbd2c1f726
point docs at non-deprecated functions
2023-02-01 09:29:38 +01:00
Greg Leonard
b244b83a64
Update deprecated methods in from_utc
example
...
`from_timestamp` and `Utc.timestamp` are deprecated, and have been replaced with `from_timestamp_opt` and `Utc.timestamp_opt` respectively, with unwrapping.
2023-01-19 11:11:02 +01:00
Dirkjan Ochtman
7c5e631fde
Apply clippy suggestions for Rust 1.66
2022-12-19 16:52:15 +01:00
Dirkjan Ochtman
a05e7aaede
Setup cargo-deny in CI
2022-12-19 16:50:30 +01:00
Dirkjan Ochtman
e02cb3e323
Skip unsound version of iana-time-zone
2022-12-19 16:50:30 +01:00
Brennan Vincent
a1591e91f3
Add from_timestamp_micros function
2022-12-15 09:46:41 +01:00
Brennan Vincent
918003e7ee
Fix MSRV violation
2022-12-14 10:28:51 +01:00
Brennan Vincent
2f14b0c870
Test that from_timestamp_millis
corresponds to from_timestamp_opt
2022-12-14 10:28:51 +01:00
Dan Dixey
5312160ce2
Fix: Typ in docstrings
2022-11-25 14:08:40 -08:00
Eric Sheppard
ff370ae656
fix bug and add more test cases
2022-11-22 22:25:25 -08:00
Eric Sheppard
e7d4402853
make NaiveTime::MIN public
2022-11-23 13:07:54 +11:00
Eric Sheppard
1624fc32bd
Fix add and sub days implemention and test with dst timezone
...
This previously called the `.datetime` field on the datetime, however this is problematic as it is in UTC time. It now correctly uses the `.naive_local()` method to get the local time as a NaiveTime
2022-11-20 19:32:22 +01:00
Michael Seele
698d14795e
Add format_localized for chrono::naive::NaiveDate
2022-11-20 19:26:55 +01:00
xmo-odoo
ff9db15b09
Clarify out of range value for from_timestamp_opt
...
The limits on the secs count has to be hunted down to the bottom of
the readme / root document, which is a bit annoying when
e.g. migrating from the deprecated `from_timestamp` and wondering why
`from_timestamp_opt` is fallible.
The nsecs limits can be inferred from the rest of the text but
explicit is better than implicit.
2022-11-16 12:42:27 +01:00
Daniel Brotsky
e7eb35f1da
Fix doc on Days::new to refer to days, not months.
...
This fixes chronotope/chrono#871
2022-11-15 12:43:13 +01:00
Dirkjan Ochtman
9e5eb49838
Bump version to 0.4.23
v0.4.23
2022-11-12 05:09:20 +01:00
Eric Sheppard
dc4287a627
store hash of environment variable
2022-11-11 13:16:10 +01:00
Eric Sheppard
57908e918b
allow sharing of the allocated environment variable
2022-11-11 13:16:10 +01:00
Eric Sheppard
84f3c30d1e
move last_changed to the Cache
2022-11-11 13:16:10 +01:00
Eric Sheppard
8bc413936f
add bench for Local::now()
2022-11-11 13:16:10 +01:00
Dirkjan Ochtman
22b4d32498
Avoid use of deprecated API
2022-11-09 13:37:17 +01:00
Dirkjan Ochtman
77317d5255
Deprecate usage of the Date<Tz> type
2022-11-09 13:37:17 +01:00
Dirkjan Ochtman
7ba090d484
Add TimeZone::with_ymd_and_hms() helper method
...
We don't add `with_yo_and_hms()` and `with_isoywd_and_hms()` here,
instead recommending users can use `from_local_datetime()` with
a separately constructed `NaiveDateTime`.
2022-11-09 13:37:17 +01:00
Dirkjan Ochtman
03165c8658
Move Date::years_since() implementation into NaiveDate
2022-11-09 13:37:17 +01:00
Dirkjan Ochtman
645fca0c55
chore: apply clippy suggestions for 1.65
2022-11-09 11:47:50 +01:00
Alex Touchet
280208499e
Fix GitHub Actions badge
2022-11-08 11:09:09 +01:00
Conrad Ludgate
3e2f151613
remove dyn formatting from timezone (-74/78% on 2822/3339 respectively)
2022-10-26 15:59:01 +02:00
Conrad Ludgate
86325bc9aa
avoid int formatting as much as possible (net -70%/-68% on 2822/3339 respectively)
2022-10-26 15:59:01 +02:00
Conrad Ludgate
8a90e128f8
skip DelayedFormat for rfc2822 (net -55% improvement for 2822)
2022-10-26 15:59:01 +02:00
Conrad Ludgate
8706fe0862
extract out locales for a later change
2022-10-26 15:59:01 +02:00
Conrad Ludgate
66491783a2
skip DelayedFormat for rfc3339 (net -58% improvement)
2022-10-26 15:59:01 +02:00
Conrad Ludgate
64e082a5f8
use less intermediate formatting (-5% improvement)
2022-10-26 15:59:01 +02:00
Sergey Potapov
b9241c0666
Implement Arbitrary for Weekday
2022-10-18 13:07:01 +02:00
Sergey Potapov
8b654b5f28
Implement Arbitrary for Month and Months
2022-10-18 13:07:01 +02:00
Sergey Potapov
87b04c5b91
Implement Arbitrary for Duration
2022-10-18 13:07:01 +02:00
Sergey Potapov
44cee53a18
Implement Arbitrary for DateTime<Tz>
2022-10-18 13:07:01 +02:00
Sergey Potapov
7af32de08a
Implement Arbitrary for Date
2022-10-18 13:07:01 +02:00
Sergey Potapov
de57f5617a
Implement Arbitrary for timezones
2022-10-18 13:07:01 +02:00
Sergey Potapov
c879b18dbf
Tweak implementation of Arbitrary for NaiveDate and NaiveTime to make it infallible
2022-10-18 13:07:01 +02:00
Alex Sayers
2eda0f1a61
Optionally implement Arbitrary for Naive{Date,Time,DateTime}
2022-10-18 13:07:01 +02:00
Dirkjan Ochtman
eb1fae64fc
Make Mdf methods fallible in the face of invalid input
2022-10-16 20:52:08 +02:00
Dirkjan Ochtman
bb874851a0
Make Of methods fallible in the face of invalid ordinals
2022-10-16 20:52:08 +02:00