aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/libs/icu/i18n/uspoof_conf.cpp
diff options
context:
space:
mode:
authormcheshkov <mcheshkov@yandex-team.ru>2022-02-10 16:46:15 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:46:15 +0300
commite9d19cec64684c9c1e6b0c98297e5b895cf904fe (patch)
tree2768b1223e96a8a0610a93d18425d9647c1123c8 /contrib/libs/icu/i18n/uspoof_conf.cpp
parent60040c91ffe701a84689b2c6310ff845e65cff42 (diff)
downloadydb-e9d19cec64684c9c1e6b0c98297e5b895cf904fe.tar.gz
Restoring authorship annotation for <mcheshkov@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'contrib/libs/icu/i18n/uspoof_conf.cpp')
-rw-r--r--contrib/libs/icu/i18n/uspoof_conf.cpp72
1 files changed, 36 insertions, 36 deletions
diff --git a/contrib/libs/icu/i18n/uspoof_conf.cpp b/contrib/libs/icu/i18n/uspoof_conf.cpp
index 1a7cdad60a..cf81460226 100644
--- a/contrib/libs/icu/i18n/uspoof_conf.cpp
+++ b/contrib/libs/icu/i18n/uspoof_conf.cpp
@@ -1,4 +1,4 @@
-// © 2016 and later: Unicode, Inc. and others.
+// © 2016 and later: Unicode, Inc. and others.
// License & terms of use: http://www.unicode.org/copyright.html
/*
******************************************************************************
@@ -8,7 +8,7 @@
*
******************************************************************************
* file name: uspoof_conf.cpp
-* encoding: UTF-8
+* encoding: UTF-8
* tab size: 8 (not used)
* indentation:4
*
@@ -76,10 +76,10 @@ SPUString::~SPUString() {
SPUStringPool::SPUStringPool(UErrorCode &status) : fVec(NULL), fHash(NULL) {
fVec = new UVector(status);
- if (fVec == NULL) {
- status = U_MEMORY_ALLOCATION_ERROR;
- return;
- }
+ if (fVec == NULL) {
+ status = U_MEMORY_ALLOCATION_ERROR;
+ return;
+ }
fHash = uhash_open(uhash_hashUnicodeString, // key hash function
uhash_compareUnicodeString, // Key Comparator
NULL, // Value Comparator
@@ -140,10 +140,10 @@ SPUString *SPUStringPool::addString(UnicodeString *src, UErrorCode &status) {
delete src;
} else {
hashedString = new SPUString(src);
- if (hashedString == NULL) {
- status = U_MEMORY_ALLOCATION_ERROR;
- return NULL;
- }
+ if (hashedString == NULL) {
+ status = U_MEMORY_ALLOCATION_ERROR;
+ return NULL;
+ }
uhash_put(fHash, src, hashedString, &status);
fVec->addElement(hashedString, status);
}
@@ -168,32 +168,32 @@ ConfusabledataBuilder::ConfusabledataBuilder(SpoofImpl *spImpl, UErrorCode &stat
if (U_FAILURE(status)) {
return;
}
-
- fTable = uhash_open(uhash_hashLong, uhash_compareLong, NULL, &status);
-
- fKeySet = new UnicodeSet();
- if (fKeySet == NULL) {
- status = U_MEMORY_ALLOCATION_ERROR;
- return;
- }
-
- fKeyVec = new UVector(status);
- if (fKeyVec == NULL) {
- status = U_MEMORY_ALLOCATION_ERROR;
- return;
- }
-
- fValueVec = new UVector(status);
- if (fValueVec == NULL) {
- status = U_MEMORY_ALLOCATION_ERROR;
- return;
- }
-
+
+ fTable = uhash_open(uhash_hashLong, uhash_compareLong, NULL, &status);
+
+ fKeySet = new UnicodeSet();
+ if (fKeySet == NULL) {
+ status = U_MEMORY_ALLOCATION_ERROR;
+ return;
+ }
+
+ fKeyVec = new UVector(status);
+ if (fKeyVec == NULL) {
+ status = U_MEMORY_ALLOCATION_ERROR;
+ return;
+ }
+
+ fValueVec = new UVector(status);
+ if (fValueVec == NULL) {
+ status = U_MEMORY_ALLOCATION_ERROR;
+ return;
+ }
+
stringPool = new SPUStringPool(status);
- if (stringPool == NULL) {
- status = U_MEMORY_ALLOCATION_ERROR;
- return;
- }
+ if (stringPool == NULL) {
+ status = U_MEMORY_ALLOCATION_ERROR;
+ return;
+ }
}
@@ -425,7 +425,7 @@ void ConfusabledataBuilder::outputData(UErrorCode &status) {
for (i=0; i<numKeys; i++) {
int32_t key = fKeyVec->elementAti(i);
UChar32 codePoint = ConfusableDataUtils::keyToCodePoint(key);
- (void)previousCodePoint; // Suppress unused variable warning.
+ (void)previousCodePoint; // Suppress unused variable warning.
// strictly greater because there can be only one entry per code point
U_ASSERT(codePoint > previousCodePoint);
keys[i] = key;