Fixed building on MSVC

This commit is contained in:
Bartek Kryza
2023-09-13 20:48:31 +02:00
parent 509358b88f
commit 7b41295b07
2 changed files with 8 additions and 5 deletions

View File

@@ -13299,9 +13299,12 @@ RegexMatcher::RegexMatcher(
bool RegexMatcher::match(std::string const &matchee) const bool RegexMatcher::match(std::string const &matchee) const
{ {
auto flags = std::regex::ECMAScript | auto flags = std::regex::ECMAScript; // ECMAScript is the default syntax
std::regex::multiline; // ECMAScript is the default syntax // option anyway
// option anyway #if !defined(_WIN32)
flags |= std::regex::multiline;
#endif
if (m_caseSensitivity == CaseSensitive::Choice::No) { if (m_caseSensitivity == CaseSensitive::Choice::No) {
flags |= std::regex::icase; flags |= std::regex::icase;
} }

View File

@@ -55,7 +55,7 @@ TEST_CASE("t00056", "[test-case][class]")
src, IsConceptRequirement(_A("iterable<T>"), "container.end()")); src, IsConceptRequirement(_A("iterable<T>"), "container.end()"));
#ifdef _MSC_VER #ifdef _MSC_VER
REQUIRE_THAT(puml, REQUIRE_THAT(src,
IsConceptRequirement( IsConceptRequirement(
_A("convertible_to_string<T>"), "std::string{s}")); _A("convertible_to_string<T>"), "std::string{s}"));
#else #else
@@ -162,7 +162,7 @@ TEST_CASE("t00056", "[test-case][class]")
src, IsConceptRequirement(_A("iterable<T>"), "container.end()")); src, IsConceptRequirement(_A("iterable<T>"), "container.end()"));
#ifdef _MSC_VER #ifdef _MSC_VER
REQUIRE_THAT(puml, REQUIRE_THAT(src,
IsConceptRequirement( IsConceptRequirement(
_A("convertible_to_string<T>"), "std::string{s}")); _A("convertible_to_string<T>"), "std::string{s}"));
#else #else