Changeset 73307 in webkit for trunk/JavaScriptCore/yarr/RegexInterpreter.h
- Timestamp:
- Dec 3, 2010, 2:48:19 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/yarr/RegexInterpreter.h
r73124 r73307 88 88 TypeCheckInput, 89 89 } type; 90 bool invertOrCapture;91 90 union { 92 91 struct { … … 115 114 }; 116 115 unsigned frameLocation; 116 bool m_capture : 1; 117 bool m_invert : 1; 117 118 int inputPosition; 118 119 119 120 ByteTerm(UChar ch, int inputPos, unsigned frameLocation, unsigned quantityCount, QuantifierType quantityType) 120 121 : frameLocation(frameLocation) 122 , m_capture(false) 123 , m_invert(false) 121 124 { 122 125 switch (quantityType) { … … 140 143 ByteTerm(UChar lo, UChar hi, int inputPos, unsigned frameLocation, unsigned quantityCount, QuantifierType quantityType) 141 144 : frameLocation(frameLocation) 145 , m_capture(false) 146 , m_invert(false) 142 147 { 143 148 switch (quantityType) { … … 162 167 ByteTerm(CharacterClass* characterClass, bool invert, int inputPos) 163 168 : type(ByteTerm::TypeCharacterClass) 164 , invertOrCapture(invert) 169 , m_capture(false) 170 , m_invert(invert) 165 171 { 166 172 atom.characterClass = characterClass; … … 170 176 } 171 177 172 ByteTerm(Type type, unsigned subpatternId, ByteDisjunction* parenthesesInfo, bool invertOrCapture, int inputPos)178 ByteTerm(Type type, unsigned subpatternId, ByteDisjunction* parenthesesInfo, bool capture, int inputPos) 173 179 : type(type) 174 , invertOrCapture(invertOrCapture) 180 , m_capture(capture) 181 , m_invert(false) 175 182 { 176 183 atom.subpatternId = subpatternId; … … 183 190 ByteTerm(Type type, bool invert = false) 184 191 : type(type) 185 , invertOrCapture(invert) 192 , m_capture(false) 193 , m_invert(invert) 186 194 { 187 195 atom.quantityType = QuantifierFixedCount; … … 189 197 } 190 198 191 ByteTerm(Type type, unsigned subpatternId, bool invertOrCapture, int inputPos)199 ByteTerm(Type type, unsigned subpatternId, bool capture, bool invert, int inputPos) 192 200 : type(type) 193 , invertOrCapture(invertOrCapture) 201 , m_capture(capture) 202 , m_invert(invert) 194 203 { 195 204 atom.subpatternId = subpatternId; … … 229 238 static ByteTerm BackReference(unsigned subpatternId, int inputPos) 230 239 { 231 return ByteTerm(TypeBackReference, subpatternId, false, inputPos);240 return ByteTerm(TypeBackReference, subpatternId, false, false, inputPos); 232 241 } 233 242 … … 298 307 bool invert() 299 308 { 300 return invertOrCapture;309 return m_invert; 301 310 } 302 311 303 312 bool capture() 304 313 { 305 return invertOrCapture;314 return m_capture; 306 315 } 307 316 };
Note:
See TracChangeset
for help on using the changeset viewer.