[libcxx-commits] [libcxx] [llvm] [libc++] Fix `regex_search` to match `$` alone with `match_default` flag (PR #77256)
Sanjay Marreddi via libcxx-commits
libcxx-commits at lists.llvm.org
Mon Jan 8 12:42:25 PST 2024
================
@@ -47,5 +47,12 @@ int main(int, char**)
assert( std::regex_search(target, re, std::regex_constants::match_not_eol));
}
+ {
+ std::string target = "foo";
+ std::regex re("$");
+ assert(std::regex_search(target, re));
+ assert(!std::regex_search(target, re, std::regex_constants::match_not_eol));
----------------
SanjayMarreddi wrote:
Done
https://github.com/llvm/llvm-project/pull/77256
More information about the libcxx-commits
mailing list