Files
2025-10-25 03:02:53 +03:00

51 lines
1.3 KiB
Markdown
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

[re.results.nonmember]
# 28 Text processing library [[text]](./#text)
## 28.6 Regular expressions library [[re]](re#results.nonmember)
### 28.6.9 Class template match_results [[re.results]](re.results#nonmember)
#### 28.6.9.9 Non-member functions [re.results.nonmember]
[🔗](#lib:operator==,match_results)
`template<class BidirectionalIterator, class Allocator>
bool operator==(const match_results<BidirectionalIterator, Allocator>& m1,
const match_results<BidirectionalIterator, Allocator>& m2);
`
[1](#1)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/text.tex#L11690)
*Returns*: true if neither match result is ready, false if one match result is ready and the
other is not[.](#1.sentence-1)
If both match results are ready, returns true only if
- [(1.1)](#1.1)
m1.empty() && m2.empty(), or
- [(1.2)](#1.2)
!m1.empty() && !m2.empty(), and the following conditions are satisfied:
* [(1.2.1)](#1.2.1)
m1.prefix() == m2.prefix(),
* [(1.2.2)](#1.2.2)
m1.size() == m2.size() && equal(m1.begin(), m1.end(), m2.begin()), and
* [(1.2.3)](#1.2.3)
m1.suffix() == m2.suffix()[.](#1.sentence-2)
[*Note [1](#note-1)*:
The algorithm equal is defined in [[algorithms]](algorithms "26Algorithms library")[.](#1.sentence-3)
— *end note*]