Skip to content
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

Use TryFrom for TimeSpec/Duration conversions which may underflow/overflow #2522

Draft
wants to merge 4 commits into
base: master
Choose a base branch
from

Commits on Oct 20, 2024

  1. Switch to TryFrom conversions for TimeSpec and Duration

    Their underlying types are not congruent and therefor "lossy"
    conversions with usually unexpected behavior result from it.
    
    Let's make this explicit by switching from From conversions to TryFrom.
    The error types used there are quite spartan. Is there a need for more
    detailed reporting?
    sirhcel committed Oct 20, 2024
    Configuration menu
    Copy the full SHA
    077d6d2 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    404aa68 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    d630718 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    65b0fc4 View commit details
    Browse the repository at this point in the history