Changeset 194387 in webkit for trunk/Source/JavaScriptCore/icu

Timestamp:
Dec 23, 2015, 2:48:26 AM (9 years ago)
Author:
[email protected]
Message:

[INTL] Implement Intl.DateTimeFormat.prototype.resolvedOptions ()
https://bugs.webkit.org/show_bug.cgi?id=147603

Patch by Andy VanWagoner <[email protected]> on 2015-12-23
Reviewed by Benjamin Poulain.

.:

  • Source/cmake/OptionsWin.cmake: Disable INTL on Windows for now

Source/JavaScriptCore:

Implements InitializeDateTimeFormat and related abstract operations
using ICU. Lazy initialization is used for DateTimeFormat.prototype.
Refactor to align with Collator work.

  • icu/unicode/udatpg.h: Added.
  • icu/unicode/unumsys.h: Added.
  • runtime/CommonIdentifiers.h:
  • runtime/IntlDateTimeFormat.cpp:

(JSC::defaultTimeZone):
(JSC::canonicalizeTimeZoneName):
(JSC::localeData):
(JSC::toDateTimeOptions):
(JSC::IntlDateTimeFormat::setFormatsFromPattern):
(JSC::IntlDateTimeFormat::initializeDateTimeFormat):
(JSC::IntlDateTimeFormat::weekdayString):
(JSC::IntlDateTimeFormat::eraString):
(JSC::IntlDateTimeFormat::yearString):
(JSC::IntlDateTimeFormat::monthString):
(JSC::IntlDateTimeFormat::dayString):
(JSC::IntlDateTimeFormat::hourString):
(JSC::IntlDateTimeFormat::minuteString):
(JSC::IntlDateTimeFormat::secondString):
(JSC::IntlDateTimeFormat::timeZoneNameString):
(JSC::IntlDateTimeFormat::resolvedOptions):
(JSC::IntlDateTimeFormat::format):
(JSC::IntlDateTimeFormatFuncFormatDateTime): Deleted.

  • runtime/IntlDateTimeFormat.h:
  • runtime/IntlDateTimeFormatConstructor.cpp:

(JSC::constructIntlDateTimeFormat):
(JSC::callIntlDateTimeFormat):

  • runtime/IntlDateTimeFormatPrototype.cpp:

(JSC::IntlDateTimeFormatFuncFormatDateTime):
(JSC::IntlDateTimeFormatPrototypeGetterFormat):
(JSC::IntlDateTimeFormatPrototypeFuncResolvedOptions):

  • runtime/IntlObject.cpp:

(JSC::resolveLocale):
(JSC::getNumberingSystemsForLocale):

  • runtime/IntlObject.h:

LayoutTests:

  • js/intl-datetimeformat-expected.txt: Added resolvedOptions tests.
  • js/script-tests/intl-datetimeformat.js: Added resolvedOptions tests.

(string_appeared_here):

Location:
trunk/Source/JavaScriptCore/icu/unicode
Files:
2 added

Note: See TracChangeset for help on using the changeset viewer.