summaryrefslogtreecommitdiffstats
path: root/9/sources/cxx-stl/llvm-libc++/libcxx/include/regex
diff options
context:
space:
mode:
Diffstat (limited to '9/sources/cxx-stl/llvm-libc++/libcxx/include/regex')
-rw-r--r--9/sources/cxx-stl/llvm-libc++/libcxx/include/regex13
1 files changed, 12 insertions, 1 deletions
diff --git a/9/sources/cxx-stl/llvm-libc++/libcxx/include/regex b/9/sources/cxx-stl/llvm-libc++/libcxx/include/regex
index 26ade48..7d922cb 100644
--- a/9/sources/cxx-stl/llvm-libc++/libcxx/include/regex
+++ b/9/sources/cxx-stl/llvm-libc++/libcxx/include/regex
@@ -964,7 +964,11 @@ public:
typedef locale locale_type;
typedef ctype_base::mask char_class_type;
- static const char_class_type __regex_word = 0x80;
+ // Note that Android's whitespace bit, aka. _B (see locale_android.cpp for
+ // the details) was unfortunately defined as 0x80 which made the whitespace
+ // character be recognized as a word.
+ static const char_class_type __regex_word = 0x200;
+
private:
locale __loc_;
const ctype<char_type>* __ct_;
@@ -4541,6 +4545,13 @@ basic_regex<_CharT, _Traits>::__parse_character_escape(_ForwardIterator __first,
__push_char(_CharT(__sum));
++__first;
break;
+ case '0':
+ if (__str)
+ *__str = _CharT(0);
+ else
+ __push_char(_CharT(0));
+ ++__first;
+ break;
default:
if (*__first != '_' && !__traits_.isctype(*__first, ctype_base::alnum))
{