Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 56241cc1137f1aa6923b80e59522406084e20637
      
https://github.com/WebKit/WebKit/commit/56241cc1137f1aa6923b80e59522406084e20637
  Author: Sosuke Suzuki <[email protected]>
  Date:   2026-08-31 (Mon, 31 Aug 2026)

  Changed paths:
    A JSTests/stress/temporal-zoned-date-time-round-sub-minute-offset-fold.js
    M Source/JavaScriptCore/runtime/TemporalZonedDateTimePrototype.cpp

  Log Message:
  -----------
  [JSC] `Temporal.ZonedDateTime.prototype.round` resolves the rounded 
wall-clock time with a minute-rounded offset
https://bugs.webkit.org/show_bug.cgi?id=322923

Reviewed by Yusuke Suzuki.

round() re-interprets the rounded wall-clock time through
InterpretISODateTimeOffset with the receiver's current offset, and the
spec passes match-exactly there: the offset came from the time zone, not
from a string that only carries minutes. JSC passed match-minutes, so
inside a sub-minute fold (Pacific/Niue moved from LMT -11:19:40 to -11:20
in 1952) a candidate whose offset merely rounds to the current one is
accepted first, and rounding a time in the second occurrence slid 20
seconds back into the first.

Pass match-exactly like with() and the property-bag path already do.

Test: JSTests/stress/temporal-zoned-date-time-round-sub-minute-offset-fold.js

* JSTests/stress/temporal-zoned-date-time-round-sub-minute-offset-fold.js: 
Added.
(shouldBe):
(throw.new.Error):
* Source/JavaScriptCore/runtime/TemporalZonedDateTimePrototype.cpp:
(JSC::JSC_DEFINE_HOST_FUNCTION):

Canonical link: https://commits.webkit.org/320217@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to