Make regex and any assert when they should throw an exception _but_ the user has decreed 'no exceptions'. This matches the behavior of string and vector

llvm-svn: 245239
diff --git a/libcxx/include/regex b/libcxx/include/regex
index 6aecd91..b355bbb 100644
--- a/libcxx/include/regex
+++ b/libcxx/include/regex
@@ -762,6 +762,7 @@
 #include <memory>
 #include <vector>
 #include <deque>
+#include <cassert>
 
 #include <__undef_min_max>
 
@@ -960,7 +961,9 @@
 void __throw_regex_error()
 {
 #ifndef _LIBCPP_NO_EXCEPTIONS
-	throw regex_error(_Ev);
+    throw regex_error(_Ev);
+#else
+    assert(!"regex_error");
 #endif
 }