37 references to Capture
System.Text.RegularExpressions.Generator (37)
RegexGenerator.Emitter.cs (6)
1582Debug.Assert(node.Kind == RegexNodeKind.Capture, "Every generated tree should begin with a capture node"); 2643Debug.Assert(node.Kind is RegexNodeKind.Capture, $"Unexpected type: {node.Kind}"); 3038case RegexNodeKind.Capture: 5576RegexNodeKind.Capture when node.M == -1 && node.N != -1 => $"Non-capturing balancing group. Uncaptures the {DescribeCapture(node.N, rm)}.", 5577RegexNodeKind.Capture when node.N != -1 => $"Balancing group. Captures the {DescribeCapture(node.M, rm)} and uncaptures the {DescribeCapture(node.N, rm)}.", 5578RegexNodeKind.Capture when node.N == -1 => $"{DescribeCapture(node.M, rm)}.",
src\libraries\System.Text.RegularExpressions\src\System\Text\RegularExpressions\RegexNode.cs (16)
243Debug.Assert(Kind == RegexNodeKind.Capture, "Every generated tree should begin with a capture node"); 302case RegexNodeKind.Capture: 372Debug.Assert(rootNode.Kind == RegexNodeKind.Capture); 495case RegexNodeKind.Capture: 919case RegexNodeKind.PositiveLookaround when ContainsKind(child, [RegexNodeKind.Capture]) is false: 1533case RegexNodeKind.Capture: 1973while (node.Kind is RegexNodeKind.Capture or RegexNodeKind.Concatenate) 2025while (loopChild.Kind is RegexNodeKind.Capture or RegexNodeKind.Concatenate) 2114if (node.Kind is RegexNodeKind.Capture) 2274while (node.Kind is RegexNodeKind.Capture or RegexNodeKind.Concatenate) 2293case RegexNodeKind.Capture: 2490case RegexNodeKind.Capture: 2548case RegexNodeKind.Capture: 2649case RegexNodeKind.Capture: 2788case RegexNodeKind.Capture: 3211case RegexNodeKind.Capture:
src\libraries\System.Text.RegularExpressions\src\System\Text\RegularExpressions\RegexParser.cs (3)
277StartGroup(new RegexNode(RegexNodeKind.Capture, (_options & ~RegexOptions.IgnoreCase), 0, -1)); 763return new RegexNode(RegexNodeKind.Capture, _options, _autocap++, -1); 937return new RegexNode(RegexNodeKind.Capture, _options, capnum, uncapnum);
src\libraries\System.Text.RegularExpressions\src\System\Text\RegularExpressions\RegexPrefixAnalyzer.cs (10)
85case RegexNodeKind.Capture: 455case RegexNodeKind.Capture: 492case RegexNodeKind.Capture: 683case RegexNodeKind.Capture: 1031case RegexNodeKind.Capture: 1138while (node.Kind is RegexNodeKind.Atomic or RegexNodeKind.Capture) 1155while (firstChild.Kind is RegexNodeKind.Atomic or RegexNodeKind.Capture) 1224while ((nextChild.Kind is RegexNodeKind.Atomic or RegexNodeKind.Capture or RegexNodeKind.Concatenate) || 1298case RegexNodeKind.Capture: 1361case RegexNodeKind.Capture:
src\libraries\System.Text.RegularExpressions\src\System\Text\RegularExpressions\RegexTreeAnalyzer.cs (2)
70case RegexNodeKind.Capture: 101RegexNodeKind.Capture => true,