[libcxx] r299652 - Restore Missing awk regex tests. Thanks to dexonsmith for noticing, and proposing this as https://reviews.llvm.org/D16541

Marshall Clow via cfe-commits cfe-commits at lists.llvm.org
Thu Apr 6 07:32:42 PDT 2017


Author: marshall
Date: Thu Apr  6 09:32:42 2017
New Revision: 299652

URL: http://llvm.org/viewvc/llvm-project?rev=299652&view=rev
Log:
Restore Missing awk regex tests. Thanks to dexonsmith for noticing, and proposing this as https://reviews.llvm.org/D16541

Modified:
    libcxx/trunk/test/std/re/re.alg/re.alg.match/awk.pass.cpp

Modified: libcxx/trunk/test/std/re/re.alg/re.alg.match/awk.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/std/re/re.alg/re.alg.match/awk.pass.cpp?rev=299652&r1=299651&r2=299652&view=diff
==============================================================================
--- libcxx/trunk/test/std/re/re.alg/re.alg.match/awk.pass.cpp (original)
+++ libcxx/trunk/test/std/re/re.alg/re.alg.match/awk.pass.cpp Thu Apr  6 09:32:42 2017
@@ -26,7 +26,7 @@
 
 int main()
 {
-/*    {
+    {
         std::cmatch m;
         const char s[] = "a";
         assert(std::regex_match(s, m, std::regex("a", std::regex_constants::awk)));
@@ -616,13 +616,12 @@ int main()
         assert(m.size() == 0);
     }
     std::locale::global(std::locale(LOCALE_cs_CZ_ISO8859_2));
-*/    {
-    /*
+    {
         std::cmatch m;
         const char s[] = "m";
-        assert(std::regex_match(s, m, std::regex("[a[=M=]z]",
-                                                 std::regex_constants::awk);
-       assert(m.size() == 1);
+        assert(std::regex_match(s, m, 
+                      std::regex("[a[=M=]z]", std::regex_constants::awk)));
+        assert(m.size() == 1);
         assert(!m.prefix().matched);
         assert(m.prefix().first == s);
         assert(m.prefix().second == m[0].first);
@@ -632,8 +631,8 @@ int main()
         assert(m.length(0) == std::char_traits<char>::length(s));
         assert(m.position(0) == 0);
         assert(m.str(0) == s);
-*/    }
-/*    {
+    }
+    {
         std::cmatch m;
         const char s[] = "Ch";
         assert(std::regex_match(s, m, std::regex("[a[.ch.]z]",
@@ -1389,4 +1388,4 @@ int main()
         assert(m.position(0) == 0);
         assert(m.str(0) == s);
     }
-*/}
+}




More information about the cfe-commits mailing list