Specification Drafts for ECMAScript Internationalization API

This page contains a historical record of working drafts of the ECMAScript Internationalization API specification prepared by the project editor.

Errors in the current draft should be reported as bugs at bugs.ecmascript.org.

Release Candidate Drafts

Current 2.0 Draft


ecma-402-2-draft-rev10-2015-02-17.doc ecma-402-2-draft-rev10-2015-02-17.pdf


ecma-402-2-draft-rev9-2015-02-09.doc ecma-402-2-draft-rev9-2015-02-09.pdf

  • Editorial Changes
    • Moved Edition 2 authors above Edition 1 at request of NL


ecma-402-2-draft-rev6-2015-01-12.doc ecma-402-2-draft-rev6-2015-01-12.pdf

  • Technical Changes
    • Updated to Ecma-262, 6th ed. specification mechanisms
    • Updated to Ecma-262, 6th ed. normative references
    • Extends the Ecma-262, 6th ed. intrinsics table
    • Adds Array.prototype.toLocaleString
    • Adds preliminary notes, re: Ecma-262, 6th ed. subclassing
  • Editorial Changes
    • 2013, 2014 → 2015
    • Update to author credits

2013-02-28 doc html pdf changes

  • Technical changes:
    • Bug 228: Allow IANA time zone names in DateTimeFormat constructor.
    • Bug 573: Locale sensitive case conversion.
    • Bug 1254: BasicFormatMatcher algorithm doesn’t initialize formatProp.
    • Bug 1256: Handling of currency option unclear in InitializeNumberFormat.
    • Bug 1258: BasicFormatMatcher 11.c.vi doesn’t handle optionsProp and formatProp being undefined.
  • Editorial changes:
    • Updated edition to 2.0.
    • Updated year to 2013.

Edition 1.0

2012-12-12 Edition 1.0 of standard ECMA-402, ECMAScript Internationalization API Specification, is available on the Ecma International web site: PDF, HTML, EPUB.

1.0 Drafts

2012-10-12 doc pdf changes 1 changes 2

  • This is the final draft submitted to Ecma GA.
  • Technical changes:
    • Removed normalization/kk option from Intl.Collator.
  • Editorial changes:
    • Removed non-Latin names of contributors because of the failure of Microsoft Word to correctly render Persian.
    • Minor adjustments to streamline the production of the HTML version.

2012-10-03 doc pdf changes 1 changes 2

  • This draft has the content approved by TC 39 for submission to Ecma CC and GA.
  • Technical changes:
    • Date-time formatting with the Gregorian calendar now uses a proleptic Gregorian calendar with no year 0.
  • Editorial changes:
    • Added Annex A: Implementation Dependent Behaviour.
    • Added one more feedback provider.

2012-09-04 doc pdf changes 1 changes 2

  • Technical changes:
    • Clarified boundaries of substrings in BestAvailableLocale and ResolveLocale.
    • Clarified that requirements for “this xxx object” also apply to functions returned by Get attributes of properties.
    • Clarified that CompareStrings works with any object initialized as a Collator; similarly for FormatNumber and FormatDateTime.
    • Changed CompareStrings so that full support for canonical equivalence is not required if normalization has been turned off. Required that the default is normalization on for all locales.
    • Added two numbering systems that were added with full specifications in version 21 of Unicode Technical Standard #35 and that use digits that were defined in Unicode 5.0.
    • Changed initializeDateTimeFormat so that hour12 is only defined when hour is also present, and that pattern and a new hourNo0 are set up for proper support of 12-hour time.
    • Changed FormatDateTime so that if hour12 is true, the algorithm sets hour = hour % 12, allows locales to display hour 0 as 12, and inserts a localized am/pm indicator.
    • Updated resolvedOptions and various property descriptions for the new handling of hour12 and the new hourNo0 and pattern12 properties.
  • Editorial changes:
    • Changed from Working Draft to Draft.
    • Added new feedback providers.
    • Minor fixes.

2012-08-13 doc pdf changes 1 changes 2

  • Technical changes:
    • Bug 419: Updated UTS 35 reference to version 21.0.1. Clarified that the new Unicode locale extension keys and values “kr”, “native”, “traditio”, and “finance” are not supported.
    • Interpret a single locale string passed as a locales argument as if it were contained within a single-element array.
    • Replaced call to Object.freeze and subsequent change to Extensible attribute with iteration over properties to make them non-writable/non-configurable.
    • Removed special handling of null in options properties interpretation.
    • Defined length properties of all functions based on ES6 rules (optional arguments don’t count).
    • Clarified that CompareStrings must interpret String values as UTF-16 code unit sequences, and interpret surrogate pairs as code points.
  • Editorial changes:
    • Added names of editor, contributors, feedback providers.
    • Added notes clarifying that additional time zone names may be accepted under certain conditions, and that they use different casing rules than plain upper case.
    • Bug 442: Added note advising how to map the names of date and time components to CLDR attributes.
    • Changed some spelling to British English, the official language of Ecma and ISO standards. Fortunately, Oxford English allows “internationalization” and “globalization”.

2012-06-28 doc pdf changes 1 changes 2

  • Technical changes:
    • Added allowance for additional values to the Conformance clause.
    • Removed Intl.LocaleList, replacing its API uses with arrays. Converted InitializeLocaleList into CanonicalizeLocaleList. Replaced internal use of LocaleList objects with List values. Made the supportedLocalesOf methods return an array whose properties are non-writable/non-configurable so that we might reintroduce LocaleList.
    • Made the format properties of NumberFormat and DateTimeFormat accessors that return functions bound to their containing objects.
    • Made resolvedOptions functions rather than accessors.
    • Changed recommendation on fallback locales in constructors’ availableLocales to a requirement.
    • Made date-time formatting use number formats without grouping.
    • Added explicit initialization of all optional arguments at the beginning of API functions and constructors. Abstract operations don’t have optional arguments anymore; they get at least undefined.
    • Changed IndexOfMatch abstract operation into BestAvailableLocale, which returns a language tag rather than an index.
    • Changed GetGetOption and GetGetNumberOption to simpler functions without currying. Made GetOption use a List of allowed values rather than an array.
    • Clarified several references to the Intl object and its properties so that the meaning doesn’t change when someone assigns to the Intl property of the global object.
    • Changed construction of prototype objects to avoid cycles in the prototype chain.
    • Clarified the meaning of “this XXX object”.
    • Added compatibility handling for NaN in Date.prototype.toLocale(|Date|Time)String.
    • Added checks to ensure that any given object is only initialized once as an instance of an Intl constructor, and that non-extensible objects are not initialized.
    • Clarified presence of internal properties of NumberFormat and DateTimeFormat, and handling of absent internal properties in resolvedOptions.
  • Editorial changes:
    • Replaced disclaimer with copyright notice.
    • Added an introduction.
    • Merged the two references sections, but kept non-normative references out.
    • Styled API identifiers and strings a bit more consistently.
    • Added recommendations to use CLDR as locale data source (Collator already recommended UCA).
    • Turned some non-normative text into notes and removed some other; added cross references instead.
    • Added notes to the descriptions of locale sensitive functions of the ECMAScript Language Specifications so that they can fully supersede the definitions in that specification.

2012-05-03 doc pdf changes 1 changes 2

  • Technical changes:
    • Changed minimal version of Unicode from 4.1 to 5.0, the version supported in Windows Vista.
    • Introduced Record specification type (similar to ES6 draft) and used it for internal-only arguments and result values of abstract operations.
    • Renamed IsValidLanguageTag to IsStructurallyValidLanguageTag and made it check for duplicate singleton and variant subtags.
    • Renamed formatMatch option to formatMatcher; renamed LookupMatch, BestFitMatch, BasicFormatMatch, BestFitFormatMatch similarly.
    • Removed support for Unicode locale extension keys “kb” (backward second level weight), “kc” (case level), and “kh” (hiragana quaternary) from Collator API.
    • Fixed bug 325: Clarified that the digits not allowed in pattern strings are those with General Category “Number, decimal digit”, and that currency names may contain such digits.
    • Changed NumberFormat.format to use the UTF-16 string representations of digits so that it doesn’t break when supplementary characters are added as digits.
    • Fixed ToDateTimeOptions and callers to allow the creation of a formatter with time elements only.

2012-02-23 doc pdf changes 1 changes 2

  • Technical changes:
    • Renamed the Globalization object to Intl.
    • Made the Intl object extensible. The restriction on extending the object was not popular, and Allen no longer thinks it makes sense to try and future-proof the object in this way.
    • Changed constructor-as-function specs to allow functions to be used for subclass initialization. Only the Intl object and undefined as “this” still lead to creating a new object. This entailed breaking out core initialization into abstract operations.
    • Rewrote algorithms to not depend on ECMAScript objects whose behavior might get compromised by other software: Inlined Array.prototype.forEach and Array.prototype.filter; replaced internal use of Array with List; replaced Put either with DefineOwnProperty or with internal properties; checked presence of properties that aren’t guaranteed to be present before Get’ing them; replaced regular expressions for currency codes and Unicode locale extension sequences with equivalent algorithm or verbal description; replaced use of String methods with verbal descriptions.
    • Changed all internal methods to abstract operations.
    • In LocaleList constructor, check all elements of the locales argument before modifying the object being initialized. Also, throw TypeError when given values of types other than String and Object are provided as language tags - this catches some invalid data earlier, but also prevents NaN from being converted to the language tag for Min Nan Chinese.
    • Made sure that all public functions convert their arguments to the types they want to work with.
    • Clarified that case mapping must not map non-ASCII characters to ASCII letters.
    • Moved prohibition of extlang form and reordering of variant subtags from note to normative text.
    • Replaced currentHostLocale internal property of Intl with DefaultLocale abstract operation.
    • Removed “initial” from the description of attributes that can’t be changed.
    • Used “initialized” internal properties to identify properly initialized objects.
    • Moved checking of requestedLocales argument from LookupSupportedLocalesOf to SupportedLocalesOf.
    • Moved checking of localeList argument from service constructors to ResolveLocale.
    • Fixed ResolveLocale to not add extension key-value pairs to the locale if their value is overridden by a different option value.
    • Fixed ResolveLocale to prefer “true” as default value if extension key has no value.
    • Fixed Collator initialization to convert boolean option values to strings for ResolveLocale.
    • Made Collator.prototype.compare a getter that returns a function bound to the collator.
    • Fixed InitializeNumberFormat to use NumberFormat’s locale data rather than DateTimeFormat’s.
    • Ensured that the currency string passed from InitializeNumberFormat to CurrencyDigits is always upper case.
    • Prohibited NumberFormat pattern strings from containing digits.
    • Fixed ToRawPrecision to cut zeroes only in the fraction part.
  • Editorial changes:
    • Renamed the standard from “ECMAScript Globalization API Specification” to “ECMAScript Internationalization API Specification”. Reorganized Overview section to focus on internationalization.
    • Added a bit of information to the Scope section.
    • Grouped normative references by organization; removed reference to IANA Language Subtag Registry; added References section.
    • Introduced abbreviation “ES5” for “ECMAScript Language Specification, 5.1 edition”.
    • Removed description of the API specification as “initial version”.
    • Allowed for variable-named internal properties.
    • Clarified “supported” in Identification of Locales, Time Zones, and Currencies.
    • Moved Requirements for Standard Built-in ECMAScript Objects into their own clause.
    • Moved locale negotiation functionality into a single section.
    • Moved some text that shouldn’t be seen as normative into notes.
    • Used “<” for “less than”, “=” for “equal to”, “≠” for “not equal to”, etc.
    • Updated year to 2012.

2011-12-01 doc pdf changes 1 changes 2

  • Technical changes:
    • Added implementation dependent best fit algorithms for locale and date-time format matching. Removed recommendation to include “equivalent” locales in available locales.
    • Added re-specifications of locale sensitive methods in ECMAScript Language Specification (localeCompare, toLocaleString, etc.)
    • Removed ValueError; replaced uses with RangeError.
    • Made LocaleList prototype an empty locale list so that LocaleList objects don’t inherit an element.
    • Added GetGetOption and GetGetNumberOption abstract operations; changed constructors to use them.
    • Added specification of interpretation of collator options in Collator.prototype.compare.
    • Completed specification of NumberFormat.prototype.format; changed it to use separate pattern strings for negative/positive decimal/percent/currency formats.
    • Changed DateTimeFormat constructor to provide default format component set even when options object is provided.
    • Removed allowance for Julian calendar before 1930.
    • Various minor fixes to algorithms.
  • Editorial changes:
    • Added links to referenced documents.
    • Created separate section on notational conventions.
    • Merged all information related to locale and parameter negotiation into new section.
    • Explained array-likeness of LocaleList.
    • Used optional arguments in constructor specifications rather than separate subsections for each argument list length.
    • Changed digits for numbering systems to Unicode escapes because Word doesn’t fully support Unicode.
    • Added recommendation to use information from IANA time zone database.
    • Noted that future versions may fill in identifier for host environment’s current time zone when no time zone is specified.

2011-10-31 doc pdf

  • Converted from working draft on Google docs.

2011-07-25 pdf

2011-07-01 wiki

globalization/specification_drafts.txt · Last modified: 2015/03/24 13:56 by rwaldron
Recent changes RSS feed Creative Commons License Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki