From c62f9f7fba3aeb36d65ca7cbaf1c3f72554f9315 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Bargull?= Date: Mon, 7 Jul 2025 07:01:34 +0200 Subject: [PATCH] Add Intl intrinsics --- harness/wellKnownIntrinsicObjects.js | 56 ++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) diff --git a/harness/wellKnownIntrinsicObjects.js b/harness/wellKnownIntrinsicObjects.js index d0d44c18c8..25e803682d 100644 --- a/harness/wellKnownIntrinsicObjects.js +++ b/harness/wellKnownIntrinsicObjects.js @@ -305,6 +305,62 @@ const WellKnownIntrinsicObjects = [ name: "%unescape%", source: "unescape", }, + + // Extensions to well-known intrinsic objects. + // + // https://tc39.es/ecma402/#sec-402-well-known-intrinsic-objects + { + name: "%Intl%", + source: "Intl", + }, + { + name: "%Intl.Collator%", + source: "Intl.Collator", + }, + { + name: "%Intl.DateTimeFormat%", + source: "Intl.DateTimeFormat", + }, + { + name: "%Intl.DisplayNames%", + source: "Intl.DisplayNames", + }, + { + name: "%Intl.DurationFormat%", + source: "Intl.DurationFormat", + }, + { + name: "%Intl.ListFormat%", + source: "Intl.ListFormat", + }, + { + name: "%Intl.Locale%", + source: "Intl.Locale", + }, + { + name: "%Intl.NumberFormat%", + source: "Intl.NumberFormat", + }, + { + name: "%Intl.PluralRules%", + source: "Intl.PluralRules", + }, + { + name: "%Intl.RelativeTimeFormat%", + source: "Intl.RelativeTimeFormat", + }, + { + name: "%Intl.Segmenter%", + source: "Intl.Segmenter", + }, + { + name: "%IntlSegmentIteratorPrototype%", + source: "Object.getPrototypeOf(new Intl.Segmenter().segment()[Symbol.iterator]())", + }, + { + name: "%IntlSegmentsPrototype%", + source: "Object.getPrototypeOf(new Intl.Segmenter().segment())", + }, ]; WellKnownIntrinsicObjects.forEach((wkio) => {