public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/109993] New: std::regex("\\a", std::regex::basic) does not diagnose invalid BRE
@ 2023-05-26 16:22 redi at gcc dot gnu.org
  0 siblings, 0 replies; only message in thread
From: redi at gcc dot gnu.org @ 2023-05-26 16:22 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109993

            Bug ID: 109993
           Summary: std::regex("\\a", std::regex::basic) does not diagnose
                    invalid BRE
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libstdc++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: redi at gcc dot gnu.org
            Blocks: 102445
  Target Milestone: ---

#include <regex>
int main()
{
 std::regex("\\a", std::regex::basic);
}

This should throw a std::regex_error exception.

https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap09.html#tag_09_03

"The interpretation of an ordinary character preceded by an unescaped
<backslash> ( '\\' ) is undefined, except for: [...]"


Referenced Bugs:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102445
[Bug 102445] [meta-bug] std::regex issues

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-05-26 16:22 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-26 16:22 [Bug libstdc++/109993] New: std::regex("\\a", std::regex::basic) does not diagnose invalid BRE redi at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).