]> granicus.if.org Git - icu/commitdiff
ICU-12647 Fix build break on Windows.
authorJeff Genovy <29107334+jefgen@users.noreply.github.com>
Thu, 15 Feb 2018 22:37:22 +0000 (22:37 +0000)
committerJeff Genovy <29107334+jefgen@users.noreply.github.com>
Thu, 15 Feb 2018 22:37:22 +0000 (22:37 +0000)
('IN' is already defined in a Windows header, so it conflicts with the variable IN.)

X-SVN-Rev: 40925

icu4c/source/i18n/regexcmp.cpp

index 4e9ad6ae4d7f3c63ac8e477b47c86dd157cd32ef..ebfb024a8a1b6f90aff9e120570cd374893b5988 100644 (file)
@@ -4450,11 +4450,11 @@ UnicodeSet *RegexCompile::createSetForProperty(const UnicodeString &propName, UB
     //    See if the property looks like a Java "InBlockName", which
     //    we will recast as "Block=BlockName"
     //
-    static const UChar IN[] = {0x49, 0x6E, 0};  // "In"
-    static const UChar BLOCK[] = {0x42, 0x6C, 0x6f, 0x63, 0x6b, 0x3d, 00};  // "Block="
-    if (mPropName.startsWith(IN, 2) && propName.length()>=3) {
+    static const UChar strIN[] = {0x49, 0x6E, 0};  // "In"
+    static const UChar strBLOCK[] = {0x42, 0x6C, 0x6f, 0x63, 0x6b, 0x3d, 00};  // "Block="
+    if (mPropName.startsWith(strIN, 2) && propName.length()>=3) {
         setExpr.truncate(4);   // Leaves "[\p{", or "[\P{"
-        setExpr.append(BLOCK, -1);
+        setExpr.append(strBLOCK, -1);
         setExpr.append(UnicodeString(mPropName, 2));  // Property with the leading "In" removed.
         setExpr.append(chRBrace);
         setExpr.append(chRBracket);