Timothy Flynn
a43cb15e81
LibJS+LibWeb: Replace JS::Utf16String with AK::Utf16String
2025-07-18 12:45:38 -04:00
Timothy Flynn
8cec9e7557
LibJS+LibUnicode: Remove unused FormatNumericToString AO
2025-07-08 11:19:27 -04:00
ayeteadoe
c14173f651
LibJS: Enable EXPLICIT_SYMBOL_EXPORT
2025-06-30 10:50:36 -06:00
Timothy Flynn
128675770c
LibJS: Implement Intl.Locale.prototype.variants
...
This is a normative change in the ECMA-402 spec. See:
e8c995a
2025-06-04 17:11:35 -04:00
Timothy Flynn
324bd0f163
LibJS: Update the Intl.Locale prototype to the latest editorial spec
...
This has been refactored a bit recently.
2025-06-04 17:11:35 -04:00
Timothy Flynn
208a5e6763
LibJS: Update the Intl.Locale constructor to the latest editorial spec
...
This has been refactored a bit recently. There are upcoming normative
changes that do not apply cleanly without this update.
2025-06-04 17:11:35 -04:00
Timothy Flynn
8e5cc74eb1
LibJS: Add notation to Intl.PluralRules
...
This is a normative change in the ECMA-402 spec. See:
a7ff535
2025-05-27 10:39:25 -04:00
Timothy Flynn
ccf03316fa
LibJS: Convert FilterLocales and CoerceOptionsToObject to GC::Ref
...
These never return nullptr.
2025-04-08 06:50:40 -04:00
Timothy Flynn
2729c88154
LibJS: Migrate remaining Intl objects to use ResolveOptions
...
This is an editorial change in the ECMA-402 spec. See:
75e67db
2025-04-08 06:50:40 -04:00
Timothy Flynn
3f55240a8e
LibJS: Migrate Intl.DisplayNames to use ResolveOptions
...
This is an editorial change in the ECMA-402 spec. See:
5eafacd
2025-04-08 06:50:40 -04:00
Timothy Flynn
636e214326
LibJS: Migrate Intl.Collator to use ResolveOptions
...
This is an editorial change in the ECMA-402 spec. See:
f822dc1
2025-04-08 06:50:40 -04:00
Timothy Flynn
e40881ebb8
LibJS: Migrate Intl.DateTimeFormat to use ResolveOptions
...
This is an editorial change in the ECMA-402 spec. See:
9e4c922
2025-04-08 06:50:40 -04:00
Timothy Flynn
d3332d51b5
LibJS: Add an AO to implement Intl constructor locale resolution
...
This is an editorial change in the ECMA-402 spec. See:
9e4c922
2025-04-08 06:50:40 -04:00
Timothy Flynn
62793b1bd8
LibJS: Define constructor slots for describing how to read options
...
This is an editorial change in the ECMA-402 spec. See:
a2beb66
We implement this change by introducing a virtual interface that all
Intl "service" objects must implement. A future patch will make use of
the virtualized RelevantExtensionKeys and ResolutionOptionDescriptors
accessors, and we will need to be able to use those slots from a generic
instance type.
2025-04-08 06:50:40 -04:00
Timothy Flynn
19ce186f97
LibJS: Define Intl.Locale's LocaleExtensionKeys more declaratively
...
This is an editorial change in the ECMA-402 spec. See:
3898acf
2025-04-08 06:50:40 -04:00
Timothy Flynn
75fce14f09
LibJS: Rename Intl.Locale's RelevantExtensionKeys to LocaleExtensionKeys
...
This is an editorial change in the ECMA-402 spec. See:
e2a5747
2025-04-08 06:50:40 -04:00
Timothy Flynn
680f028bb8
LibJS: Simplify Intl.Collator sensitivity / ignorePunctuation defaults
...
This is an editorial change in the ECMA-402 spec. See:
23e2e92
2025-04-08 06:50:40 -04:00
Timothy Flynn
b81d0d3261
LibJS: Ensure Intl.Collator instances have [[Numeric]] and [[CaseFirst]]
...
This is an editorial change in the ECMA-402 spec. See:
243ec38
2025-04-08 06:50:40 -04:00
Timothy Flynn
0f1fa38442
LibJS: Update spec link for FormatNumericToString AO
...
This is an editorial change in the ECMA-402 spec. See:
e3f7260
Note the other changes in this commit do not apply to our implementation
as we defer to ICU for the affected steps.
2025-04-08 06:50:40 -04:00
Timothy Flynn
0a256b0a9a
AK+Everywhere: Change StringView case conversions to return String
...
There's a bit of a UTF-8 assumption with this change. But nearly every
caller of these methods were immediately creating a String from the
resulting ByteString anyways.
2025-04-07 17:44:38 +02:00
Andreas Kling
d7908dbff5
LibJS: Change PropertyKey(ByteString) to PropertyKey(String)
...
...and deal with the fallout.
2025-03-24 22:27:17 +00:00
Timothy Flynn
780de1395b
LibJS: Merge Intl.DurationFormat style and display fields into a struct
...
This is an editorial change in the ECMA-402 spec. See:
d56d624
2025-03-18 11:47:23 -04:00
Timothy Flynn
00d00b84d3
LibJS: Ensure relevant extension keys are included in ICU locale data
...
This is a normative change in the ECMA-402 spec. See:
7508197
In our implementation, we don't have the affected AOs directly, as we
delegate to ICU. So instead, we must ensure we provide ICU a locale with
the relevant extension keys present.
2025-03-18 11:47:23 -04:00
Timothy Flynn
37b8ba96f1
LibJS: Use currency digits for NumberFormat only for standard notation
...
This is a normative change in the ECMA-402 spec. See:
9140da2
2025-03-18 11:47:23 -04:00
Timothy Flynn
96c059bf67
LibJS: Use correct enum casing in some Intl constructors
2025-03-18 11:47:23 -04:00
Timothy Flynn
532f156f4a
LibJS: Remove some single-use Intl.DurationFormat variables
...
This is an editorial change in the ECMA-402 spec. See:
4c139f1
da498c2
ed5c716
2025-03-04 07:36:10 -05:00
Timothy Flynn
1e462daa9b
LibJS: Simplify the Intl.DurationFormat GetDurationUnitOptions AO
...
This is an editorial change in the ECMA-402 spec. See:
d097048
2025-03-04 07:36:10 -05:00
Timothy Flynn
2f023c2d9c
LibJS: Simplify Intl.DurationFormat.prototype.resolvedOptions
...
This is an editorial change in the ECMA-402 spec. See:
e3d3406
2025-03-04 07:36:10 -05:00
Timothy Flynn
56a6daee4d
LibJS: Standardize the spec-order of Intl.DurationFormat definitions
...
This is an editorial change in the ECMA-402 spec. See:
54ca35d
6cdcab3
e4cbfba
2025-03-04 07:36:10 -05:00
Timothy Flynn
aa61307392
LibJS: Re-arrange and rename a few Intl properties
...
This is an editorial change in the ECMA-402 spec. See:
a46e37d
e102741
67a8417
ecb086c
2025-03-04 07:36:10 -05:00
Timothy Flynn
8f51d1dd04
LibJS: Integrate Temporal.Duration into Intl.DurationFormat
...
This is a normative change in the Temporal proposal. See:
2d97205
2025-03-01 14:49:20 +01:00
Timothy Flynn
aa737bb654
LibJS: Migrate ToIntegerIfIntegral to ECMA-262
...
This is an editorial change in the Temporal proposal. See:
5f76109
2025-03-01 14:49:20 +01:00
Timothy Flynn
a8d6e5c3db
LibJS: Migrate Temporal updates to ECMA-262 AOs to the main AO file
...
These are going to be included in the ECMA-262 AOs once Temporal reaches
stage 4. There's no need to keep them in the Temporal namespace. Some
upcoming Temporal editorial changes will get awkward without this patch.
2025-03-01 14:49:20 +01:00
Timothy Flynn
5764eeab05
LibJS: Update spec numbers for the Intl.DurationFormat proposal
...
This proposal has reached stage 4 and was merged into the ECMA-402 spec.
See: 3ff3cc7
2025-03-01 14:49:20 +01:00
Timothy Flynn
97f7cb805f
LibJS: Remove errant invocation to FormatNumericUnits
...
This is an editorial change in the Intl.DurationFormat proposal. See:
cdef892
2025-02-06 10:46:04 -05:00
Timothy Flynn
313c050a61
LibJS: Do not override the timeZoneName option in Intl.DateTimeFormat
...
This is an editorial change in the Temporal proposal. See:
d76d11b
2025-01-17 10:08:06 +01:00
Timothy Flynn
27478ec7d4
Everywhere: Run clang-format
...
The following command was used to clang-format these files:
clang-format-19 -i $(find . \
-not \( -path "./\.*" -prune \) \
-not \( -path "./Build/*" -prune \) \
-not \( -path "./Toolchain/*" -prune \) \
-type f -name "*.cpp" -o -name "*.mm" -o -name "*.h")
2024-12-28 05:39:32 -08:00
Andreas Kling
3bfb0534be
LibGC: Rename MarkedVector => RootVector
...
Let's try to make it a bit more clear that this is a Vector of GC roots.
2024-12-26 19:10:44 +01:00
Timothy Flynn
0bc55424c8
LibJS: Fix variable reference in CreateDateTimeFormat
...
This is an editorial change in the Temporal proposal. See:
8acd353
2024-12-11 08:43:54 -08:00
Timothy Flynn
234f218803
LibJS: Ensure GetDateTimeFormat returns nonnull for the best format
...
This is an editorial change in the Temporal proposal. See:
8a52801
2024-12-06 11:13:10 -05:00
Timothy Flynn
7104d724ee
LibJS: Simplify condition in GetDateTimeFormat
...
This is an editorial change in the Temporal proposal. See:
23c74b6
2024-12-06 11:13:10 -05:00
Timothy Flynn
5e534f4d83
LibJS+LibUnicode: Designate a sort order for Intl.PluralRules categories
...
This is a normative change in the ECMA-402 spec. See:
62fe5db
2024-12-05 09:49:55 +01:00
Timothy Flynn
e5ec8441c9
LibJS: Remove the Intl.PluralRules GetOperands AO
...
This is an editorial change in the ECMA-402 spec. See:
c7bca3a
2024-12-05 09:49:55 +01:00
Timothy Flynn
3c64e4595a
LibJS: Use exact mathematical values for Intl.DurationFormat
...
We can't use doubles due to precision loss for extremely large values.
2024-12-04 08:01:35 -05:00
Timothy Flynn
5cfd50224c
LibJS: Use enums instead of strings in Intl.DurationFormat AOs
2024-12-04 08:01:35 -05:00
Timothy Flynn
37fc9b6511
LibJS: Apply editorial updates to Intl.DurationFormat
...
To help prepare for its stage 4 promotion, this applies the editorial
updates made to Intl.DurationFormat over the last few months.
2024-12-04 08:01:35 -05:00
Timothy Flynn
ea503a4f68
LibJS+LibUnicode: Integrate Temporal into Intl.DateTimeFormat
...
The gist is that we need to construct an ICU date-time formatter for
each possible Temporal type. This is of course going to be expensive.
So instead, we construct the configurations needed for the ICU objects
in the Intl.DateTimeFormat constructor, and defer creating the actual
ICU objects until they are needed.
Each formatting prototype can also now accept either a number (as they
already did), or any of the supported Temporal objects. These types may
not be mixed, and their properties (namely, their calendar) must align
with the Intl.DateTimeFormat object.
2024-11-29 09:52:12 +01:00
Timothy Flynn
c6fccc04e1
LibJS: Use Temporal's ISO8601 parser to parse UTC offset strings
...
We now have the Temporal facilities to implement the Date AOs which
parse UTC offset strings using the ISO8601 parser. This patch updates
those AOs and their callers in accordance with the Temporal spec.
2024-11-21 19:24:25 -05:00
Timothy Flynn
e4e05837e1
LibJS: Return a GC::Ref from Temporal::get_options_object
...
The Object returned here is always non-null.
2024-11-20 19:04:30 -05:00
Timothy Flynn
dd6acfecd4
LibJS: Don't use Temporal to parse UTC offset strings
...
The production for these strings has been removed from Temporal. This
implements a separate parser in accordance with the Date spec.
2024-11-18 17:46:41 -05:00