Left over from how these methods worked at one time
const timeZone = Object.create(Temporal.TimeZone.prototype, {
getPossibleInstantsFor() { ... },
getOffsetNanosecondsFor() { ... },
toString() { return"my own UTC variant" },
});
timeZone.toJSON() === "my own UTC variant"// Intended: throw due to timeZone not having correct internal slot// According to current spec text: true
Note: no change if you inherit TimeZone. This only affects objects that don't have the internal slots
Wrong rounding for fractional Duration strings (#1907)
Was floor, should have been trunc
Temporal.Duration.from('PT1.03125H').toString()
// "PT1H1M52.5S" (no change)
Temporal.Duration.from('-PT1.03125H').toString()
// Intended: "-PT1H1M52.5S"// According to current spec text: "-PT1H2M53.5S"
Missing calendar annotations in ISO strings (#1950)
Some calendar annotations forgotten in the ISO 8601 grammar
PlainTime strings like 15:13:45[u-ca=iso8601] should be allowed
Necessary if we ever want to include time calendars in a future proposal without breaking the web
PlainYearMonth and PlainMonthDay strings like 2021-12-14[u-ca=iso8601] should be allowed
When parsing 2020-12-14T07:45:24.12345-00:00:00.321[+11:11:11.54321], TimeFractionalPart could refer either to 12345 or 54321 according to the ISO 8601 grammar in the proposal
Disambiguate this by referring to separate productions
Note that a lot of the ambiguities arise because ISO 8601 allows omitting the colon in a time representation (this is called "basic format" whereas the format with the colon is called "extended format")