https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83600
--- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> --- Author: redi Date: Fri Jan 5 22:48:00 2018 New Revision: 256298 URL: https://gcc.gnu.org/viewcvs?rev=256298&root=gcc&view=rev Log: PR libstdc++/83600 fix end iterator for unready std::match_results Backport from mainline 2017-12-27 Jonathan Wakely <jwak...@redhat.com> PR libstdc++/83600 * include/bits/regex.h (match_results::end()): Return valid iterator when not ready. * testsuite/28_regex/match_results/ctors/char/default.cc: Check that unready objects are empty and have equal begin and end iterators. * testsuite/28_regex/match_results/ctors/wchar_t/default.cc: Likewise. Modified: branches/gcc-6-branch/libstdc++-v3/ChangeLog branches/gcc-6-branch/libstdc++-v3/include/bits/regex.h branches/gcc-6-branch/libstdc++-v3/testsuite/28_regex/match_results/ctors/char/default.cc branches/gcc-6-branch/libstdc++-v3/testsuite/28_regex/match_results/ctors/wchar_t/default.cc