You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
after std search, smatch is 0
after boost search, smatch is 2
STD (cppreference.com) says: the object match is updated as follows: If the match does not exist: match.ready() == true; match.empty() == true; match.size() == 0
While Boost docs says: Postconditions: If the function returns false, then the effect on parameter match is undefined
This assumption contradicts with the logic and expectations of end-user, that if no match was found in text, then the boost::match_result object state would represent it through empty and size methods. Everything said is related to boost::regex_match too.
The text was updated successfully, but these errors were encountered:
@Artalus I was going to say to file an issue at boost::regex, but then I saw you already did. I'm just writing this so others know you files the issue as well. You could just close it here.
STD (cppreference.com) says:
the object match is updated as follows: If the match does not exist: match.ready() == true; match.empty() == true; match.size() == 0
While Boost docs says:
Postconditions: If the function returns false, then the effect on parameter match is undefined
This assumption contradicts with the logic and expectations of end-user, that if no match was found in text, then the
boost::match_result
object state would represent it throughempty
andsize
methods. Everything said is related toboost::regex_match
too.The text was updated successfully, but these errors were encountered: