diff --git a/libcxx/docs/Status/SpaceshipProjects.csv b/libcxx/docs/Status/SpaceshipProjects.csv --- a/libcxx/docs/Status/SpaceshipProjects.csv +++ b/libcxx/docs/Status/SpaceshipProjects.csv @@ -188,13 +188,13 @@ "| `[fs.class.directory.entry] `_ | `[fs.dir.entry.obs] `_",| `filesystem::directory_entry `_,None,Adrian Vogelsgesang,|Complete| - `5.15 Clause 30: Regular expressions library `_,,,, -| `[re.syn] `_,|,None,Mark de Wever,|In Progress| +| `[re.syn] `_,|,None,Mark de Wever,|Complete| | `[re.submatch.op] `_,| `sub_match `_,None,Mark de Wever,|Complete| -| `[re.results.nonmember] `_,| remove ops `match_results`,None,Mark de Wever,|In Progress| +| `[re.results.nonmember] `_,| remove ops `match_results`,None,Mark de Wever,|Complete| "| `[re.regiter] `_, -| `[re.regiter.comp] `_",| remove ops `regex_iterator`,None,Mark de Wever,|In Progress| +| `[re.regiter.comp] `_",| remove ops `regex_iterator`,None,Mark de Wever,|Complete| "| `[re.tokiter] `_ -| `[re.tokiter.comp] `_",| remove ops `regex_token_iterator`,None,Mark de Wever,|In Progress| +| `[re.tokiter.comp] `_",| remove ops `regex_token_iterator`,None,Mark de Wever,|Complete| - `5.16 Clause 31: Atomic operations library `_,,,, - `5.17 Clause 32: Thread support library `_,,,, | `[thread.thread.id] `_,| `thread::id `_,None,Adrian Vogelsgesang,|Complete| diff --git a/libcxx/include/regex b/libcxx/include/regex --- a/libcxx/include/regex +++ b/libcxx/include/regex @@ -543,7 +543,7 @@ operator==(const match_results& m1, const match_results& m2); -template +template // Removed in C++20 bool operator!=(const match_results& m1, const match_results& m2); @@ -710,7 +710,7 @@ regex_iterator& operator=(const regex_iterator&); bool operator==(const regex_iterator&) const; - bool operator!=(const regex_iterator&) const; + bool operator!=(const regex_iterator&) const; // Removed in C++20 const value_type& operator*() const; const value_type* operator->() const; @@ -768,7 +768,7 @@ regex_token_iterator& operator=(const regex_token_iterator&); bool operator==(const regex_token_iterator&) const; - bool operator!=(const regex_token_iterator&) const; + bool operator!=(const regex_token_iterator&) const; // Removed in C++20 const value_type& operator*() const; const value_type* operator->() const; @@ -5816,6 +5816,7 @@ __x.__suffix_ == __y.__suffix_; } +#if _LIBCPP_STD_VER < 20 template inline _LIBCPP_INLINE_VISIBILITY bool @@ -5824,6 +5825,7 @@ { return !(__x == __y); } +#endif template inline _LIBCPP_INLINE_VISIBILITY @@ -6427,8 +6429,10 @@ #endif bool operator==(const regex_iterator& __x) const; +#if _LIBCPP_STD_VER < 20 _LIBCPP_INLINE_VISIBILITY bool operator!=(const regex_iterator& __x) const {return !(*this == __x);} +#endif _LIBCPP_INLINE_VISIBILITY reference operator*() const {return __match_;} @@ -6606,7 +6610,9 @@ bool operator==(const regex_token_iterator& __x) const; _LIBCPP_INLINE_VISIBILITY +#if _LIBCPP_STD_VER < 20 bool operator!=(const regex_token_iterator& __x) const {return !(*this == __x);} +#endif _LIBCPP_INLINE_VISIBILITY const value_type& operator*() const {return *__result_;} diff --git a/libcxx/modules/std/regex.cppm b/libcxx/modules/std/regex.cppm --- a/libcxx/modules/std/regex.cppm +++ b/libcxx/modules/std/regex.cppm @@ -64,9 +64,6 @@ // [re.submatch.op], sub_match non-member operators using std::operator==; using std::operator<=>; -# if 1 // P1614 - using std::operator!=; -# endif using std::operator<<; diff --git a/libcxx/test/std/re/re.iter/re.regiter/re.regiter.comp/tested_elsewhere.pass.cpp b/libcxx/test/std/re/re.iter/re.regiter/re.regiter.comp/tested_elsewhere.pass.cpp --- a/libcxx/test/std/re/re.iter/re.regiter/re.regiter.comp/tested_elsewhere.pass.cpp +++ b/libcxx/test/std/re/re.iter/re.regiter/re.regiter.comp/tested_elsewhere.pass.cpp @@ -11,7 +11,7 @@ // class regex_iterator // bool operator==(const regex_iterator& right) const; -// bool operator!=(const regex_iterator& right) const; +// bool operator!=(const regex_iterator& right) const; // generated by the compiler in C++20 int main(int, char**) { diff --git a/libcxx/test/std/re/re.iter/re.tokiter/re.tokiter.comp/equal.pass.cpp b/libcxx/test/std/re/re.iter/re.tokiter/re.tokiter.comp/equal.pass.cpp --- a/libcxx/test/std/re/re.iter/re.tokiter/re.tokiter.comp/equal.pass.cpp +++ b/libcxx/test/std/re/re.iter/re.tokiter/re.tokiter.comp/equal.pass.cpp @@ -11,7 +11,7 @@ // class regex_token_iterator // bool operator==(const regex_token_iterator& right) const; -// bool operator!=(const regex_token_iterator& right) const; +// bool operator!=(const regex_token_iterator& right) const; // generated by the compiler in C++20 #include #include diff --git a/libcxx/test/std/re/re.results/re.results.nonmember/equal.pass.cpp b/libcxx/test/std/re/re.results/re.results.nonmember/equal.pass.cpp --- a/libcxx/test/std/re/re.results/re.results.nonmember/equal.pass.cpp +++ b/libcxx/test/std/re/re.results/re.results.nonmember/equal.pass.cpp @@ -15,7 +15,7 @@ // operator==(const match_results& m1, // const match_results& m2); -// template +// template // generated by the compiler in C++20 // bool // operator!=(const match_results& m1, // const match_results& m2);