-
Notifications
You must be signed in to change notification settings - Fork 574
Chrono interoperability and Ops for Timestamp, update Nix and README #1307
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
…other develop rust_minimum_version for tests
- Implement Add, Sub and Div math operations; - Create unitary testes for Ops; - Create kani tests for ops; - Update kani tests for chrono conversions; - Add unitary testes for chrono conversions.
- Add support for MSRV tokio with `nix develop .#rust_minimum_version`; - Update readme, with this nix command.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like the code changes. Please split into three PRs so that I can review them separately.
| /// `Timestamp`s are likely representable on 64-bit Unix-like platforms, but other platforms, | ||
| /// such as Windows and 32-bit Linux, may not be able to represent the full range of | ||
| /// `Timestamp`s. | ||
| #[cfg(feature = "std")] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems like a breaking change
| } | ||
|
|
||
| #[cfg(feature = "chrono")] | ||
| mod p_chrono { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's not abbreviate short words: proof_chrono
| mod p_chrono { | ||
| use super::*; | ||
| use ::chrono::{DateTime, NaiveDate, NaiveDateTime}; | ||
| //Why does it limit? In testing, it was left for more than 2 hours and not completed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does this comment mean?
| let seconds = kani::any(); | ||
| let nanos = kani::any(); | ||
|
|
||
| kani::assume(i64::MAX / 3 < seconds); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why divide by 3? Please explain the the code
First of all, a huge thanks to all the contributors for this great library!
Changes:
Arithmetic Operations for Timestamp
Enhanced chrono Interoperability, with chrono feature
Nix Development Environment Update
nix develop .#rust_minimum_versionnow correctly sets up a development shell with the appropriate Minimum Supported Rust Version (MSRV) required by Tokio.A Note on the README
I have updated the README.md to include documentation for the new Nix command. However, I noticed that the
check-readmeCI job is configured to fail automatically on any modification to the README.This pull request introduces NO breaking changes.