summaryrefslogtreecommitdiff
path: root/chromium/v8/src/objects/js-number-format.cc
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2020-10-12 14:27:29 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2020-10-13 09:35:20 +0000
commitc30a6232df03e1efbd9f3b226777b07e087a1122 (patch)
treee992f45784689f373bcc38d1b79a239ebe17ee23 /chromium/v8/src/objects/js-number-format.cc
parent7b5b123ac58f58ffde0f4f6e488bcd09aa4decd3 (diff)
downloadqtwebengine-chromium-85-based.tar.gz
BASELINE: Update Chromium to 85.0.4183.14085-based
Change-Id: Iaa42f4680837c57725b1344f108c0196741f6057 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'chromium/v8/src/objects/js-number-format.cc')
-rw-r--r--chromium/v8/src/objects/js-number-format.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/chromium/v8/src/objects/js-number-format.cc b/chromium/v8/src/objects/js-number-format.cc
index c5b3d06fcaf..0abcd0cbcfc 100644
--- a/chromium/v8/src/objects/js-number-format.cc
+++ b/chromium/v8/src/objects/js-number-format.cc
@@ -207,7 +207,7 @@ std::map<const std::string, icu::MeasureUnit> CreateUnitMap() {
class UnitFactory {
public:
UnitFactory() : map_(CreateUnitMap()) {}
- virtual ~UnitFactory() {}
+ virtual ~UnitFactory() = default;
// ecma402 #sec-issanctionedsimpleunitidentifier
icu::MeasureUnit create(const std::string& unitIdentifier) {
@@ -482,16 +482,16 @@ Handle<String> SignDisplayString(Isolate* isolate,
} // anonymous namespace
// Return the minimum integer digits by counting the number of '0' after
-// "integer-width/+" in the skeleton.
+// "integer-width/*" in the skeleton.
// Ex: Return 15 for skeleton as
-// “currency/TWD .00 rounding-mode-half-up integer-width/+000000000000000”
+// “currency/TWD .00 rounding-mode-half-up integer-width/*000000000000000”
// 1
// 123456789012345
-// Return default value as 1 if there are no "integer-width/+".
+// Return default value as 1 if there are no "integer-width/*".
int32_t JSNumberFormat::MinimumIntegerDigitsFromSkeleton(
const icu::UnicodeString& skeleton) {
- // count the number of 0 after "integer-width/+"
- icu::UnicodeString search("integer-width/+");
+ // count the number of 0 after "integer-width/*"
+ icu::UnicodeString search("integer-width/*");
int32_t index = skeleton.indexOf(search);
if (index < 0) return 1; // return 1 if cannot find it.
index += search.length();