47 references to Concatenate
System.Text.RegularExpressions.Generator (47)
RegexGenerator.Emitter.cs (5)
1933case RegexNodeKind.Concatenate when child.Child(0) == startingLiteralNode && (startingLiteralNode.Kind is RegexNodeKind.One or RegexNodeKind.Set or RegexNodeKind.Multi): 2938case RegexNodeKind.Concatenate: 3100Debug.Assert(node.Kind is RegexNodeKind.Concatenate, $"Unexpected type: {node.Kind}"); 5579RegexNodeKind.Concatenate => "Match a sequence of expressions.", 5753RegexNodeKind.Concatenate when node.Parent is not { Kind: RegexNodeKind.Alternate or RegexNodeKind.BackreferenceConditional or RegexNodeKind.ExpressionConditional } => true,
src\libraries\System.Text.RegularExpressions\src\System\Text\RegularExpressions\RegexNode.cs (29)
138Kind == RegexNodeKind.Concatenate && 318case RegexNodeKind.Concatenate: 419case RegexNodeKind.Concatenate: 426if (node.Parent is { Kind: RegexNodeKind.Concatenate } parent) 496case RegexNodeKind.Concatenate when !rtl: 593RegexNodeKind.Concatenate => ReduceConcatenation(), 612Debug.Assert(Kind is RegexNodeKind.Alternate or RegexNodeKind.Concatenate); 1208if (child.Kind != RegexNodeKind.Concatenate || child.ChildCount() < 2) 1278var newConcat = new RegexNode(RegexNodeKind.Concatenate, alternation.Options); 1435ProcessOneOrMulti(branch.Kind == RegexNodeKind.Concatenate ? branch.Child(0) : branch, startingSpan); 1480var newConcat = new RegexNode(RegexNodeKind.Concatenate, startingNodeOptions); 1500RegexNode branch = Kind == RegexNodeKind.Concatenate ? Child(0) : this; 1532case RegexNodeKind.Concatenate: 1622Debug.Assert(Kind == RegexNodeKind.Concatenate); 1664Debug.Assert(Kind == RegexNodeKind.Concatenate); 1681if (at.Kind == RegexNodeKind.Concatenate && 1747Debug.Assert(Kind == RegexNodeKind.Concatenate); 1949if (Kind is not RegexNodeKind.Concatenate) 1973while (node.Kind is RegexNodeKind.Capture or RegexNodeKind.Concatenate) 2025while (loopChild.Kind is RegexNodeKind.Capture or RegexNodeKind.Concatenate) 2274while (node.Kind is RegexNodeKind.Capture or RegexNodeKind.Concatenate) 2292case RegexNodeKind.Concatenate: 2494case RegexNodeKind.Concatenate: 2533Debug.Assert(node.Kind is not RegexNodeKind.Concatenate, "The existing logic assumes that the node itself isn't a concatenation."); 2552case RegexNodeKind.Concatenate: 2636case RegexNodeKind.Concatenate: 2765case RegexNodeKind.Concatenate: 2842Debug.Assert(Kind == RegexNodeKind.Concatenate, $"Expected Concatenate, got {Kind}"); 2943Debug.Assert(Kind == RegexNodeKind.Concatenate, $"Expected Concatenate, got {Kind}");
src\libraries\System.Text.RegularExpressions\src\System\Text\RegularExpressions\RegexParser.cs (3)
521_concatenation = new RegexNode(RegexNodeKind.Concatenate, _options); 2069_concatenation = new RegexNode(RegexNodeKind.Concatenate, _options); 2086_concatenation = new RegexNode(RegexNodeKind.Concatenate, _options);
src\libraries\System.Text.RegularExpressions\src\System\Text\RegularExpressions\RegexPrefixAnalyzer.cs (9)
212case RegexNodeKind.Concatenate: 363case RegexNodeKind.Concatenate: 497case RegexNodeKind.Concatenate: 696case RegexNodeKind.Concatenate: 1050case RegexNodeKind.Concatenate: 1142if (node.Kind != RegexNodeKind.Concatenate) 1224while ((nextChild.Kind is RegexNodeKind.Atomic or RegexNodeKind.Capture or RegexNodeKind.Concatenate) || 1309case RegexNodeKind.Concatenate: 1373case RegexNodeKind.Concatenate:
src\libraries\System.Text.RegularExpressions\src\System\Text\RegularExpressions\RegexTreeAnalyzer.cs (1)
105RegexNodeKind.Concatenate => i == childCount - 1,