kparzysz created this revision.
kparzysz added a reviewer: EricWF.
kparzysz added a subscriber: cfe-commits.
kparzysz set the repository for this revision to rL LLVM.

The characters like '\xDA' or '\xFA' are not valid representations of anything 
in UTF-8, so toupper and tolower return the character itself in that locale.


Repository:
  rL LLVM

https://reviews.llvm.org/D25811

Files:
  
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_1.pass.cpp
  
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_many.pass.cpp
  
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_1.pass.cpp
  
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_many.pass.cpp


Index: 
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_many.pass.cpp
===================================================================
--- 
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_many.pass.cpp
+++ 
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_many.pass.cpp
@@ -35,7 +35,7 @@
             std::string in("\xFA A\x07.a1");
 
             assert(f.toupper(&in[0], in.data() + in.size()) == in.data() + 
in.size());
-            assert(in[0] == '\xDA');
+            assert(in[0] == '\xFA');
             assert(in[1] == ' ');
             assert(in[2] == 'A');
             assert(in[3] == '\x07');
Index: 
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_1.pass.cpp
===================================================================
--- 
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_1.pass.cpp
+++ 
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_1.pass.cpp
@@ -39,7 +39,7 @@
             assert(f.toupper('a') == 'A');
             assert(f.toupper('1') == '1');
             assert(f.toupper('\xDA') == '\xDA');
-            assert(f.toupper('\xFA') == '\xDA');
+            assert(f.toupper('\xFA') == '\xFA');
         }
     }
     {
Index: 
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_many.pass.cpp
===================================================================
--- 
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_many.pass.cpp
+++ 
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_many.pass.cpp
@@ -35,7 +35,7 @@
             std::string in("\xDA A\x07.a1");
 
             assert(f.tolower(&in[0], in.data() + in.size()) == in.data() + 
in.size());
-            assert(in[0] == '\xFA');
+            assert(in[0] == '\xDA');
             assert(in[1] == ' ');
             assert(in[2] == 'a');
             assert(in[3] == '\x07');
Index: 
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_1.pass.cpp
===================================================================
--- 
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_1.pass.cpp
+++ 
test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_1.pass.cpp
@@ -38,7 +38,7 @@
             assert(f.tolower('.') == '.');
             assert(f.tolower('a') == 'a');
             assert(f.tolower('1') == '1');
-            assert(f.tolower('\xDA') == '\xFA');
+            assert(f.tolower('\xDA') == '\xDA');
             assert(f.tolower('\xFA') == '\xFA');
         }
     }


Index: test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_many.pass.cpp
===================================================================
--- test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_many.pass.cpp
+++ test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_many.pass.cpp
@@ -35,7 +35,7 @@
             std::string in("\xFA A\x07.a1");
 
             assert(f.toupper(&in[0], in.data() + in.size()) == in.data() + in.size());
-            assert(in[0] == '\xDA');
+            assert(in[0] == '\xFA');
             assert(in[1] == ' ');
             assert(in[2] == 'A');
             assert(in[3] == '\x07');
Index: test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_1.pass.cpp
===================================================================
--- test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_1.pass.cpp
+++ test/std/localization/locale.categories/category.ctype/locale.ctype.byname/toupper_1.pass.cpp
@@ -39,7 +39,7 @@
             assert(f.toupper('a') == 'A');
             assert(f.toupper('1') == '1');
             assert(f.toupper('\xDA') == '\xDA');
-            assert(f.toupper('\xFA') == '\xDA');
+            assert(f.toupper('\xFA') == '\xFA');
         }
     }
     {
Index: test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_many.pass.cpp
===================================================================
--- test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_many.pass.cpp
+++ test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_many.pass.cpp
@@ -35,7 +35,7 @@
             std::string in("\xDA A\x07.a1");
 
             assert(f.tolower(&in[0], in.data() + in.size()) == in.data() + in.size());
-            assert(in[0] == '\xFA');
+            assert(in[0] == '\xDA');
             assert(in[1] == ' ');
             assert(in[2] == 'a');
             assert(in[3] == '\x07');
Index: test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_1.pass.cpp
===================================================================
--- test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_1.pass.cpp
+++ test/std/localization/locale.categories/category.ctype/locale.ctype.byname/tolower_1.pass.cpp
@@ -38,7 +38,7 @@
             assert(f.tolower('.') == '.');
             assert(f.tolower('a') == 'a');
             assert(f.tolower('1') == '1');
-            assert(f.tolower('\xDA') == '\xFA');
+            assert(f.tolower('\xDA') == '\xDA');
             assert(f.tolower('\xFA') == '\xFA');
         }
     }
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to