浏览代码

Toralf Niebuhr: This is just a tiny patch fixing some small (probably copy & paste) errors.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@134843 91177308-0d34-0410-b5e6-96231b3b80d8
Howard Hinnant 14 年之前
父节点
当前提交
66f2641ac9
共有 1 个文件被更改,包括 3 次插入3 次删除
  1. 3 3
      src/locale.cpp

+ 3 - 3
src/locale.cpp

@@ -926,7 +926,7 @@ ctype<char>::do_toupper(char_type* low, const char_type* high) const
 #ifndef _LIBCPP_STABLE_APPLE_ABI
 #ifndef _LIBCPP_STABLE_APPLE_ABI
         *low = isascii(*low) ? __classic_upper_table()[*low] : *low;
         *low = isascii(*low) ? __classic_upper_table()[*low] : *low;
 #else
 #else
-        *low = isascii(*low) ? _DefaultRuneLocale.__mapupper[c] : c;
+        *low = isascii(*low) ? _DefaultRuneLocale.__mapupper[*low] : *low;
 #endif
 #endif
     return low;
     return low;
 }
 }
@@ -948,7 +948,7 @@ ctype<char>::do_tolower(char_type* low, const char_type* high) const
 #ifndef _LIBCPP_STABLE_APPLE_ABI
 #ifndef _LIBCPP_STABLE_APPLE_ABI
         *low = isascii(*low) ? __classic_lower_table()[*low] : *low;
         *low = isascii(*low) ? __classic_lower_table()[*low] : *low;
 #else
 #else
-        *low = isascii(*low) ? _DefaultRuneLocale.__maplower[c] : c;
+        *low = isascii(*low) ? _DefaultRuneLocale.__maplower[*low] : *low;
 #endif
 #endif
     return low;
     return low;
 }
 }
@@ -999,7 +999,7 @@ ctype<char>::classic_table()  _NOEXCEPT
 #endif
 #endif
 }
 }
 
 
-#ifndef _LIBCPP_APPLE_STABLE_ABI
+#ifndef _LIBCPP_STABLE_APPLE_ABI
 const int*
 const int*
 ctype<char>::__classic_lower_table() _NOEXCEPT
 ctype<char>::__classic_lower_table() _NOEXCEPT
 {
 {