10 writes to _options
System.Text.RegularExpressions (10)
System\Text\RegularExpressions\RegexParser.cs (10)
61_options = options; 263_options = options; 376_options = (RegexOptions)_optionsStack.Pop(); 788_options &= ~RegexOptions.RightToLeft; 794_options &= ~RegexOptions.RightToLeft; 822_options |= RegexOptions.RightToLeft; 833_options |= RegexOptions.RightToLeft; 1563_options &= ~options; 1567_options |= options; 1702_options = (RegexOptions)_optionsStack.Pop();
73 references to _options
System.Text.RegularExpressions (73)
System\Text\RegularExpressions\RegexParser.cs (73)
277StartGroup(new RegexNode(RegexNodeKind.Capture, (_options & ~RegexOptions.IgnoreCase), 0, -1)); 290if ((_options & RegexOptions.IgnorePatternWhitespace) != 0) 332_unit = RegexNode.CreateOneWithCaseConversion(_pattern[endpos - 1], _options, _culture, ref _caseBehavior); 346string setString = ScanCharClass((_options & RegexOptions.IgnoreCase) != 0, scanOnly: false)!.ToStringClass(); 347_unit = new RegexNode(RegexNodeKind.Set, _options & ~RegexOptions.IgnoreCase, setString); 352_optionsStack.Append((int)_options); 394_unit = new RegexNode((_options & RegexOptions.Multiline) != 0 ? RegexNodeKind.Bol : RegexNodeKind.Beginning, _options); 398_unit = new RegexNode((_options & RegexOptions.Multiline) != 0 ? RegexNodeKind.Eol : RegexNodeKind.EndZ, _options); 402_unit = (_options & RegexOptions.Singleline) != 0 ? 403new RegexNode(RegexNodeKind.Set, _options & ~RegexOptions.IgnoreCase, RegexCharClass.AnyClass) : 404new RegexNode(RegexNodeKind.Notone, _options & ~RegexOptions.IgnoreCase, '\n'); 521_concatenation = new RegexNode(RegexNodeKind.Concatenate, _options); 564if ((_options & RegexOptions.ECMAScript) != 0 && _pattern[_pos] == ']') 594charClass!.AddDigit((_options & RegexOptions.ECMAScript) != 0, ch == 'D', _pattern, _pos); 606charClass!.AddSpace((_options & RegexOptions.ECMAScript) != 0, ch == 'S'); 619charClass!.AddWord((_options & RegexOptions.ECMAScript) != 0, ch == 'W'); 756if ((_options & RegexOptions.ExplicitCapture) != 0 || _ignoreNextParen) 759return new RegexNode(RegexNodeKind.Group, _options); 763return new RegexNode(RegexNodeKind.Capture, _options, _autocap++, -1); 937return new RegexNode(RegexNodeKind.Capture, _options, capnum, uncapnum); 959return new RegexNode(RegexNodeKind.BackreferenceConditional, _options, capnum); 973return new RegexNode(RegexNodeKind.BackreferenceConditional, _options, tmpCapnum); 1026return new RegexNode(nodeType, _options); 1041if ((_options & RegexOptions.IgnorePatternWhitespace) != 0) 1049if ((_options & RegexOptions.IgnorePatternWhitespace) != 0 && _pos < _pattern.Length && _pattern[_pos] == '#') 1091new RegexNode(TypeFromCode(ch), _options); 1096new RegexNode(RegexNodeKind.Set, (_options & ~RegexOptions.IgnoreCase), (_options & RegexOptions.ECMAScript) != 0 ? RegexCharClass.ECMAWordClass : RegexCharClass.WordClass); 1101new RegexNode(RegexNodeKind.Set, (_options & ~RegexOptions.IgnoreCase), (_options & RegexOptions.ECMAScript) != 0 ? RegexCharClass.NotECMAWordClass : RegexCharClass.NotWordClass); 1106new RegexNode(RegexNodeKind.Set, (_options & ~RegexOptions.IgnoreCase), (_options & RegexOptions.ECMAScript) != 0 ? RegexCharClass.ECMASpaceClass : RegexCharClass.SpaceClass); 1111new RegexNode(RegexNodeKind.Set, (_options & ~RegexOptions.IgnoreCase), (_options & RegexOptions.ECMAScript) != 0 ? RegexCharClass.NotECMASpaceClass : RegexCharClass.NotSpaceClass); 1116new RegexNode(RegexNodeKind.Set, (_options & ~RegexOptions.IgnoreCase), (_options & RegexOptions.ECMAScript) != 0 ? RegexCharClass.ECMADigitClass : RegexCharClass.DigitClass); 1121new RegexNode(RegexNodeKind.Set, (_options & ~RegexOptions.IgnoreCase), (_options & RegexOptions.ECMAScript) != 0 ? RegexCharClass.NotECMADigitClass : RegexCharClass.NotDigitClass); 1132cc.AddCategoryFromName(ParseProperty(), ch != 'p', (_options & RegexOptions.IgnoreCase) != 0, _pattern, _pos); 1133if ((_options & RegexOptions.IgnoreCase) != 0) 1138return new RegexNode(RegexNodeKind.Set, (_options & ~RegexOptions.IgnoreCase), cc.ToStringClass()); 1203IsCaptureSlot(capnum) ? new RegexNode(RegexNodeKind.Backreference, _options, capnum) : 1212if ((_options & RegexOptions.ECMAScript) != 0) 1235return scanOnly ? null : new RegexNode(RegexNodeKind.Backreference, _options, capnum); 1249return new RegexNode(RegexNodeKind.Backreference, _options, capnum); 1269_capnames?[capname] is int tmpCapnum ? new RegexNode(RegexNodeKind.Backreference, _options, tmpCapnum) : 1280RegexNode.CreateOneWithCaseConversion(ch, _options, _culture, ref _caseBehavior) : 1289return RegexNode.CreateOneWithCaseConversion('$', _options, _culture, ref _caseBehavior); 1314if (!angled && (_options & RegexOptions.ECMAScript) != 0) 1345return new RegexNode(RegexNodeKind.Backreference, _options, capnum); 1355return new RegexNode(RegexNodeKind.Backreference, _options, capnum); 1367return new RegexNode(RegexNodeKind.Backreference, _options, tmpCapnum); 1379return RegexNode.CreateOneWithCaseConversion('$', _options, _culture, ref _caseBehavior); 1405return new RegexNode(RegexNodeKind.Backreference, _options, capnum); 1412return RegexNode.CreateOneWithCaseConversion('$', _options, _culture, ref _caseBehavior); 1443if ((_options & RegexOptions.ECMAScript) != 0 && i >= 0x20) 1609if ((_options & RegexOptions.ECMAScript) == 0 && RegexCharClass.IsBoundaryWordChar(ch)) 1656'b' => (_options & RegexOptions.ECMAScript) != 0 ? RegexNodeKind.ECMABoundary : RegexNodeKind.Boundary, 1657'B' => (_options & RegexOptions.ECMAScript) != 0 ? RegexNodeKind.NonECMABoundary : RegexNodeKind.NonBoundary, 1688if ((_options & RegexOptions.IgnorePatternWhitespace) != 0) 1715_optionsStack.Append((int)_options); 1746optionsFoundInPattern |= _options; 1773if ((_options & RegexOptions.ExplicitCapture) == 0 && !_ignoreNextParen) 2018_concatenation!.AddChild(RegexNode.CreateOneWithCaseConversion(_pattern[pos], isReplacement ? _options & ~RegexOptions.IgnoreCase : _options, _culture, ref _caseBehavior)); 2021case > 1 when (_options & RegexOptions.IgnoreCase) == 0 || isReplacement || !RegexCharClass.ParticipatesInCaseConversion(_pattern.AsSpan(pos, cch)): 2022_concatenation!.AddChild(new RegexNode(RegexNodeKind.Multi, _options & ~RegexOptions.IgnoreCase, _pattern.Substring(pos, cch))); 2028_concatenation!.AddChild(RegexNode.CreateOneWithCaseConversion(c, _options, _culture, ref _caseBehavior)); 2068_alternation = new RegexNode(RegexNodeKind.Alternate, _options); 2069_concatenation = new RegexNode(RegexNodeKind.Concatenate, _options); 2086_concatenation = new RegexNode(RegexNodeKind.Concatenate, _options);