33 <!ENTITY nbsp "   " >
44] >
55
6- <issue num =" 1450" status =" Deferred " >
6+ <issue num =" 1450" status =" Open " >
77<title >[FCD] Contradiction in regex_constants</title >
88<section ><sref ref =" [re.matchflag]" /></section >
99<submitter >BSI</submitter >
@@ -61,9 +61,8 @@ So, actually <em>both</em> <tt>regex_constants::match_default</tt> and
6161<p >The proposed resolution is written against N3126 and considered as a further improvement
6262of the fixes suggested by <a href =" http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2010/n3110.html" >n3110</a >.
6363</p >
64- </discussion >
6564
66- <resolution >
65+ <note >
6766<p >
6867Add the following sentence to <sref ref =" [re.matchflag]" /> paragraph 1:
6968</p >
@@ -74,6 +73,72 @@ rules of the grammar specified for the regular expression object, modified accor
7473Table 136 for any bitmask elements set. <ins >Type <tt >regex_constants::match_flag_type</tt > also defines the
7574constants <tt >regex_constants::match_default</tt > and <tt >regex_constants::format_default</tt >.</ins >
7675</p ></blockquote >
76+ </note >
77+
78+ <note >
79+ 2011 Bloomington
80+ </note >
81+
82+ <p >
83+ It appears the key problem is the phrasing of the bitmask requirements. Jeremiah supplies updated wording.
84+ </p >
85+
86+ <p >
87+ Pete Becker has also provided an alternative resolution.
88+ </p >
89+
90+ <p >
91+ Ammend <sref ref =" [bitmask.types]" />:
92+ </p >
93+ <p >
94+ Change the list of values for "enum bit mask" in p2 from
95+ </p >
96+ <p >
97+ <tt ><i >V0</i > = 1 << 0, <i >V1</i > = 1 << 1, <i >V2</i > = 1 << 2, <i >V3</i > = 1 << 3, ...</tt >.
98+ </p >
99+ <p >
100+ to
101+ </p >
102+ <p >
103+ <tt ><i >V0</i > = 0, <i >V1</i > = 1 << 0, <i >V2</i > = 1 << 1, <i >V3</i > = 1 << 2, ...</tt >.
104+ </p >
105+ <p >
106+ Here, the names <i >C0</i >, <i >C1</i >, etc. represent <i >bitmask elements</i > for this particular
107+ bitmask type. All such <ins >non-zero</ins > elements have distinct values such that, for any pair
108+ <i >Ci</i > and <i >Cj</i > <ins >where <i >i</i > != <i >j</i ></ins >, <del ><i >Ci & Ci</i > is nonzero
109+ and</del > <i >Ci & Cj</i > is zero.
110+ </p >
111+ <p >
112+ Change bullet 3 of paragraph 4:
113+ </p >
114+ <p >
115+ <del >The</del ><ins >A non-zero</ins > value Y is set in the object X if the expression X & Y is nonzero.
116+ </p >
117+ </discussion >
118+
119+ <resolution >
120+ <p >
121+ Ammend <sref ref =" [bitmask.types]" /> p3:
122+ </p >
123+ <p >
124+ Here, the names <i >C0</i >, <i >C1</i >, etc. represent <i >bitmask elements</i > for this particular
125+ bitmask type. All such elements have distinct<ins >, non-zero</ins > values such that, for any pair
126+ <i >Ci</i > and <i >Cj</i > <ins >where <i >i</i > != <i >j</i >,</ins > <i >Ci & Ci</i > is nonzero
127+ and <i >Ci & Cj</i > is zero. <ins >Additionally, the value 0 is used to represent an
128+ <i >empty bitmask</i >, in which no bitmask elements are set.</ins >
129+ </p >
130+
131+ <p >
132+ Add the following sentence to <sref ref =" [re.matchflag]" /> paragraph 1:
133+ </p >
134+ <blockquote ><p >
135+ 1 The type <tt >regex_constants::match_flag_type</tt > is an implementation-defined bitmask type (17.5.2.1.3).
136+ <ins >The constants of that type, except for <tt >match_default</tt > and <tt >format_default</tt >, are bitmask
137+ elements. The <tt >match_default</tt > and <tt >format_default</tt > constants are empty bitmasks.</ins > Matching
138+ a regular expression against a sequence of characters [first,last) proceeds according to the rules of the
139+ grammar specified for the regular expression object, modified according to the effects listed in Table 136
140+ for any bitmask elements set.
141+ </p ></blockquote >
77142</resolution >
78143
79144</issue >
0 commit comments