This page is a snapshot from the LWG issues list, see the Library Active Issues List for more information and the meaning of C++14 status.

### 2053. Errors in `regex` bitmask types

Section: 32.4 [re.const] Status: C++14 Submitter: Jonathan Wakely Opened: 2011-05-09 Last modified: 2016-01-28

Priority: Not Prioritized

View all issues with C++14 status.

Discussion:

When N3110 was applied to the WP some redundant "static" keywords were added and one form of initializer which isn't valid for enumeration types was replaced with another form of invalid initializer.

[ 2011 Bloomington. ]

Move to Ready.

Proposed resolution:

This wording is relative to the FDIS.

1. Change 32.4.2 [re.synopt] as indicated:

   >     namespace std {
   >       namespace regex_constants {
   >         typedef T1 syntax_option_type;
   >         static constexpr syntax_option_type icase = unspecified ;
   >         static constexpr syntax_option_type nosubs = unspecified ;
   >         static constexpr syntax_option_type optimize = unspecified ;
   >         static constexpr syntax_option_type collate = unspecified ;
   >         static constexpr syntax_option_type ECMAScript = unspecified ;
   >         static constexpr syntax_option_type basic = unspecified ;
   >         static constexpr syntax_option_type extended = unspecified ;
   >         static constexpr syntax_option_type awk = unspecified ;
   >         static constexpr syntax_option_type grep = unspecified ;
   >         static constexpr syntax_option_type egrep = unspecified ;
   >       }
   >     }

2. Change 32.4.3 [re.matchflag] as indicated:

   >     namespace std {
   >       namespace regex_constants {
   >         typedef T2 match_flag_type;
   >         static constexpr match_flag_type match_default = 0{};
   >         static constexpr match_flag_type match_not_bol = unspecified ;
   >         static constexpr match_flag_type match_not_eol = unspecified ;
   >         static constexpr match_flag_type match_not_bow = unspecified ;
   >         static constexpr match_flag_type match_not_eow = unspecified ;
   >         static constexpr match_flag_type match_any = unspecified ;
   >         static constexpr match_flag_type match_not_null = unspecified ;
   >         static constexpr match_flag_type match_continuous = unspecified ;
   >         static constexpr match_flag_type match_prev_avail = unspecified ;
   >         static constexpr match_flag_type format_default = 0{};
   >         static constexpr match_flag_type format_sed = unspecified ;
   >         static constexpr match_flag_type format_no_copy = unspecified ;
   >         static constexpr match_flag_type format_first_only = unspecified ;
   >       }
   >     }

3. Change 32.4.4 [re.err] as indicated:

   >     namespace std {
   >       namespace regex_constants {
   >         typedef T3 error_type;
   >         static constexpr error_type error_collate = unspecified ;
   >         static constexpr error_type error_ctype = unspecified ;
   >         static constexpr error_type error_escape = unspecified ;
   >         static constexpr error_type error_backref = unspecified ;
   >         static constexpr error_type error_brack = unspecified ;
   >         static constexpr error_type error_paren = unspecified ;
   >         static constexpr error_type error_brace = unspecified ;
   >         static constexpr error_type error_badbrace = unspecified ;
   >         static constexpr error_type error_range = unspecified ;
   >         static constexpr error_type error_space = unspecified ;
   >         static constexpr error_type error_badrepeat = unspecified ;
   >         static constexpr error_type error_complexity = unspecified ;
   >         static constexpr error_type error_stack = unspecified ;
   >       }
   >     }