mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-04 18:23:39 +00:00
When formatting a currency style pattern with compact notation, we were (trying to) doubly insert the currency symbol into the formatted string. We would first look up the currency pattern in GetNumberFormatPattern (for the en locale, this is "¤#,##0.00", which our generator transforms to "{currency}{number}"). When we hit the "{number}" field, NumberFormat will do a second lookup for the compact pattern to use for the number being formatted. By using the currency compact patterns, we receive a second pattern that also has the currency symbol (for the en locale, if formatting the number 1000, this is "¤0K", which our generator transforms to "{currency}{number}{compactIdentifier:0}". This second lookup is not supposed to have currency symbols (or any other symbols), thus we hit a VERIFY_NOT_REACHED(). Instead, we are meant to use the decimal compact pattern, and allow the currency symbol to be handled by only the outer currency pattern. |
||
---|---|---|
.. | ||
NumberFormat.@@toStringTag.js | ||
NumberFormat.js | ||
NumberFormat.prototype.format.js | ||
NumberFormat.prototype.formatRange.js | ||
NumberFormat.prototype.formatRangeToParts.js | ||
NumberFormat.prototype.formatToParts.js | ||
NumberFormat.prototype.resolvedOptions.js | ||
NumberFormat.supportedLocalesOf.js |