mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 04:57:44 +00:00
LibJS: Drop "integral part of" language
This is an editorial change in the Temporal spec.
See: 6ec1608
This commit is contained in:
parent
cb33320814
commit
9a3014c91a
3 changed files with 6 additions and 6 deletions
|
@ -453,7 +453,7 @@ ThrowCompletionOr<NanosecondsToDaysResult> nanoseconds_to_days(GlobalObject& glo
|
|||
|
||||
// 4. If Type(relativeTo) is not Object or relativeTo does not have an [[InitializedTemporalZonedDateTime]] internal slot, then
|
||||
if (!relative_to_value.is_object() || !is<ZonedDateTime>(relative_to_value.as_object())) {
|
||||
// a. Return the Record { [[Days]]: the integral part of nanoseconds / dayLengthNs, [[Nanoseconds]]: (abs(nanoseconds) modulo dayLengthNs) × sign, [[DayLength]]: dayLengthNs }.
|
||||
// a. Return the Record { [[Days]]: RoundTowardsZero(nanoseconds / dayLengthNs), [[Nanoseconds]]: (abs(nanoseconds) modulo dayLengthNs) × sign, [[DayLength]]: dayLengthNs }.
|
||||
return NanosecondsToDaysResult {
|
||||
.days = nanoseconds.divided_by(day_length_ns).quotient.to_double(),
|
||||
.nanoseconds = Crypto::SignedBigInteger { nanoseconds.unsigned_value() }.divided_by(day_length_ns).remainder.multiplied_by(Crypto::SignedBigInteger { (i32)sign }),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue