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

Add rounding to Date.difference and YearMonth.difference #982

Merged
merged 3 commits into from
Oct 14, 2020

Commits on Oct 13, 2020

  1. Use LargerOfTwoTemporalDurationUnits in one more place

    I missed this one before because it wasn't in the spec yet (since we don't
    delegate to the calendar yet in DateTime.difference).
    ptomato committed Oct 13, 2020
    Configuration menu
    Copy the full SHA
    0f97723 View commit details
    Browse the repository at this point in the history
  2. Add rounding to Date.difference

    We don't have Date.round because calendar rounding needs a reference
    point, but in Date.difference we have a reference point (`this`).
    
    See: #908
    ptomato committed Oct 13, 2020
    Configuration menu
    Copy the full SHA
    d014e8a View commit details
    Browse the repository at this point in the history
  3. Add rounding to YearMonth.difference

    For the same reason as we can add it to Date.difference, `this` is used as
    the reference point.
    
    See: #908
    ptomato committed Oct 13, 2020
    Configuration menu
    Copy the full SHA
    5a4ef33 View commit details
    Browse the repository at this point in the history