Continuing to work through regex, and updated libcxx_by_chapter.pdf with weekly test results

llvm-svn: 106790
Cr-Mirrored-From: sso://chromium.googlesource.com/_direct/external/github.com/llvm/llvm-project
Cr-Mirrored-Commit: 24e98486a3b6076bfa1b5fac5c2be0ec264d10c9
diff --git a/src/regex.cpp b/src/regex.cpp
index abb1b66..9cc6eb5 100644
--- a/src/regex.cpp
+++ b/src/regex.cpp
@@ -20,33 +20,40 @@
     switch (ecode)
     {
     case regex_constants::error_collate:
-        return "error_collate";
+        return "The expression contained an invalid collating element name.";
     case regex_constants::error_ctype:
-        return "error_ctype";
+        return "The expression contained an invalid character class name.";
     case regex_constants::error_escape:
-        return "error_escape";
+        return "The expression contained an invalid escaped character, or a "
+               "trailing escape.";
     case regex_constants::error_backref:
-        return "error_backref";
+        return "The expression contained an invalid back reference.";
     case regex_constants::error_brack:
-        return "error_brack";
+        return "The expression contained mismatched [ and ].";
     case regex_constants::error_paren:
-        return "error_paren";
+        return "The expression contained mismatched ( and ).";
     case regex_constants::error_brace:
-        return "error_brace";
+        return "The expression contained mismatched { and }.";
     case regex_constants::error_badbrace:
-        return "error_badbrace";
+        return "The expression contained an invalid range in a {} expression.";
     case regex_constants::error_range:
-        return "error_range";
+        return "The expression contained an invalid character range, "
+               "such as [b-a] in most encodings.";
     case regex_constants::error_space:
-        return "error_space";
+        return "There was insufficient memory to convert the expression into "
+               "a finite state machine.";
     case regex_constants::error_badrepeat:
-        return "error_badrepeat";
+        return "One of *?+{ was not preceded by a valid regular expression.";
     case regex_constants::error_complexity:
-        return "error_complexity";
+        return "The complexity of an attempted match against a regular "
+               "expression exceeded a pre-set level.";
     case regex_constants::error_stack:
-        return "error_stack";
+        return "There was insufficient memory to determine whether the regular "
+               "expression could match the specified character sequence.";
+    default:
+        break;
     }
-    return "unknown error_type";
+    return "Unknown error type";
 }
 
 regex_error::regex_error(regex_constants::error_type ecode)