<style> /* make code examples suck less */ pre code { margin: 0 !important; font-size: 1.25em !important; } pre { padding: 0 !important; text-align: left !important; } .align-left { text-align: left !important; } .small-li li { font-size: 0.85em !important; } </style> # Intl Era Month Code proposal for Stage 3 --- ### Ben Allen, 111th TC39 --- ## Premise * `Temporal` supports a number of non ISO-8601 calendars * The behaviour of these calendars has always been defined outside of ECMAScript (in practice, CLDR + ICU4C/ICU4X) * `Temporal` adds calendar arithmetic capability * Although we don't want to specify the arithmetic for every calendar, we do want guardrails around implementation—defined behaviour in order to avoid implementation divergence --- ## Goal 1. We shouldn't overspecify behavior for matters on which ECMAScript isn't the correct authority 1. Within that constraint, minimize opportunities for implementation divergence --- ## Additions to ECMA-402 * Descriptions of supported calendars, removing potential ambiguities. * List of valid era codes and aliases, as standardized in CLDR. * Valid ranges for era years for each calendar. * Expanded range for selection of reference years. * List of epoch years per calendar for `Temporal.PlainDate.prototype.year`. --- ## Additions to ECMA-402 * List of epoch years per calendar for `Temporal.PlainDate.prototype.year` * Specifics on which calendars support eras and week numbers --- ## Additions to ECMA-402 * Constraining behaviour when adding years in lunisolar calendars * Algorithm for determining the difference between two dates * Special handling for CLDR Hijri calendar IDs with implementation-defined algorithm --- ## Normative changes * We have two small normative changes --- ## Normative changes * [Normative: Delete superfluous era aliases to align with CLDR #72](https://github.com/tc39/proposal-intl-era-monthcode/pull/72) * CLDR is removing several era aliases: `"incar"` and `"mundi"` for the `"ethiopic"` calendar, and `"before-roc"`, `"minguo"`, and `"minguo-qian"` for the `"roc"` calendar. * This PR syncs Era Month Code with CLDR. --- ## Normative changes * [Normative: Remove spurious/unnecessary check for "out of range" era](https://github.com/tc39/proposal-intl-era-monthcode/pull/89) * Previously we had a spurious check for "out of range" era years. These values have always been permitted and are in fact necessary for the Japanese imperial regnal calendar. This PR removes that check. --- ## Normative changes * Our only remaining next step from September was the creation of test262 tests for the proposal * Extensive tests for Era Month Code have been completed! --- ## Stage 3? --- ## Next steps * Implementation! --- ## Thank you! ---
{"type":"slide","slideOptions":{"theme":"igalia"}}