forked from js-temporal/temporal-polyfill
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Polyfill: Implement rounding towards Big Bang in epoch time getters
See #2423 for the issue and #2424 for the spec text change, which was already adopted some time ago. I thought the reference code already worked like this, but it does not. Anba pointed this out in tc39/test262#3802 and provided correct test262 tests for the feature. Note that the big-integer library doesn't have a floor division function. We roll our own. If the divisor or dividend is negative (but not both) and there is a remainder, then we subtract 1 from the result (round towards negative infinity instead of 0). UPSTREAM_COMMIT=6e0ad2030170540084a4a400005cc2bc8c791bdb
- Loading branch information
1 parent
04f9195
commit 10b557f
Showing
4 changed files
with
16 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters