]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/i18n/rbt_pars.cpp
ICU-64243.0.1.tar.gz
[apple/icu.git] / icuSources / i18n / rbt_pars.cpp
index a9561c01d9ec4b823aeaa27232e872af77057f0e..9932dbdc95e3cc06bf35d035797ddc5e6060634a 100644 (file)
@@ -1,3 +1,5 @@
+// © 2016 and later: Unicode, Inc. and others.
+// License & terms of use: http://www.unicode.org/copyright.html
 /*
  **********************************************************************
  *   Copyright (C) 1999-2016, International Business Machines
@@ -192,9 +194,9 @@ const UnicodeFunctor* ParseData::lookupMatcher(UChar32 ch) const {
     const UnicodeFunctor* set = NULL;
     int32_t i = ch - data->variablesBase;
     if (i >= 0 && i < variablesVector->size()) {
-        int32_t i = ch - data->variablesBase;
-        set = (i < variablesVector->size()) ?
-            (UnicodeFunctor*) variablesVector->elementAt(i) : 0;
+        int32_t j = ch - data->variablesBase;
+        set = (j < variablesVector->size()) ?
+            (UnicodeFunctor*) variablesVector->elementAt(j) : 0;
     }
     return set;
 }
@@ -1106,8 +1108,8 @@ void TransliteratorParser::parseRules(const UnicodeString& rule,
             }
             
             data->variableNames.removeAll();
-            int32_t pos = UHASH_FIRST;
-            const UHashElement* he = variableNames.nextElement(pos);
+            int32_t p = UHASH_FIRST;
+            const UHashElement* he = variableNames.nextElement(p);
             while (he != NULL) {
                 UnicodeString* tempus = (UnicodeString*)(((UnicodeString*)(he->value.pointer))->clone());
                 if (tempus == NULL) {
@@ -1116,7 +1118,7 @@ void TransliteratorParser::parseRules(const UnicodeString& rule,
                 }
                 data->variableNames.put(*((UnicodeString*)(he->key.pointer)),
                     tempus, status);
-                he = variableNames.nextElement(pos);
+                he = variableNames.nextElement(p);
             }
         }
         variablesVector.removeAllElements();   // keeps them from getting deleted when we succeed