9 writes to Ch
System.Text.RegularExpressions (9)
System\Text\RegularExpressions\RegexNode.cs (9)
61Ch = ch; 191Ch = '\0'; 199Ch = '\0'; 1023Ch = RegexCharClass.SingletonChar(Str); 1033Ch = RegexCharClass.SingletonChar(Str); 1498node.Ch = '\0'; 1512node.Ch = node.Str[node.Str.Length - 1]; 1982nextNode.Ch = nextNode.Str[nextNode.Str.Length - 1]; 3305Ch = '\0';
119 references to Ch
System.Text.RegularExpressions (119)
System\Text\RegularExpressions\RegexCompiler.cs (20)
3258Ldc(node.Ch); 3676Ldc(literal.Ch); 3681Ldc(literal.Ch); 3918(literal.Range.LowInclusive <= node.Ch && node.Ch <= literal.Range.HighInclusive))) // for ranges, only allow when the range overlaps with the target, since there's no accelerated way to search for the union 3931overlap = literal.String[0] == node.Ch; 3935Ldc(node.Ch); 3941Ldc(node.Ch); 3948overlap = literal.SetChars.Contains(node.Ch); 3973Ldc(node.Ch); 3981EmitIndexOfAnyWithSearchValuesOrLiteral($"{node.Ch}{literal.SetChars}"); 3987overlap = literal.Range.LowInclusive == node.Ch; 3991Ldc(node.Ch); 3997Ldc(node.Ch); 4039Ldc(node.Ch); 4539EmitMultiCharString(new string(node.Ch, iterations), emitLengthChecksIfRequired, rtl); 4730Ldc(node.Ch); 4845Ldc(node.Ch); 4967Ldc(node.Ch); 5494Ldc(node.Ch);
System\Text\RegularExpressions\RegexNode.cs (73)
96new RegexNode(Kind, Options, Ch); 198Str = new string(Ch, N); 1193prevCharClass.AddChar(prev.Ch); 1202prevCharClass.AddChar(at.Ch); 1286required.Ch != other.Ch || 1416scratchChar[0] = startingNode.Ch; 1436if (startingSpan[0] != startingNode.Ch) 1496Debug.Assert(startingSpan[0] == node.Ch); 1559return IsOneFamily ? Ch : Str![0]; 1678return new StartingLiteralData(range: (node.Ch, node.Ch), negated: false); 1681return new StartingLiteralData(range: (node.Ch, node.Ch), negated: true); 1837prev.Str = prev.Ch.ToString(); 1841((at.Kind == RegexNodeKind.One) ? $"{prev.Str}{at.Ch}" : prev.Str + at.Str) : 1842((at.Kind == RegexNodeKind.One) ? $"{at.Ch}{prev.Str}" : at.Str + prev.Str); 1905case RegexNodeKind.Oneloop or RegexNodeKind.Oneloopatomic or RegexNodeKind.Onelazy or RegexNodeKind.Notoneloop or RegexNodeKind.Notoneloopatomic or RegexNodeKind.Notonelazy when nextNode.Kind == currentNode.Kind && currentNode.Ch == nextNode.Ch: 1931case RegexNodeKind.Oneloop or RegexNodeKind.Onelazy when nextNode.Kind == RegexNodeKind.One && currentNode.Ch == nextNode.Ch: 1932case RegexNodeKind.Notoneloop or RegexNodeKind.Notonelazy when nextNode.Kind == RegexNodeKind.Notone && currentNode.Ch == nextNode.Ch: 1950currentNode.Ch == nextNode.Str![0]: 1955while (matchingCharsInMulti < nextNode.Str.Length && currentNode.Ch == nextNode.Str[matchingCharsInMulti]) 1999case RegexNodeKind.One when (nextNode.Kind is RegexNodeKind.Oneloop or RegexNodeKind.Oneloopatomic or RegexNodeKind.Onelazy) && currentNode.Ch == nextNode.Ch: 2000case RegexNodeKind.Notone when (nextNode.Kind is RegexNodeKind.Notoneloop or RegexNodeKind.Notoneloopatomic or RegexNodeKind.Notonelazy) && currentNode.Ch == nextNode.Ch: 2014case RegexNodeKind.Notone when nextNode.Kind == currentNode.Kind && currentNode.Ch == nextNode.Ch: 2413case RegexNodeKind.One when CharInLoopSet(loopNode, literal.Ch): // e.g. \w+a\s : 'a' is in \w, check \s is disjoint 2438RegexNodeKind.Oneloop => loopNode.Ch == ch, 2439RegexNodeKind.Notoneloop => loopNode.Ch != ch, 2538case RegexNodeKind.One when node.Ch != subsequent.Ch: 2539case RegexNodeKind.Notone when node.Ch == subsequent.Ch: 2540case RegexNodeKind.Set when !RegexCharClass.CharInClass(node.Ch, subsequent.Str!): 2541case RegexNodeKind.Onelazy or RegexNodeKind.Oneloop or RegexNodeKind.Oneloopatomic when subsequent.M > 0 && node.Ch != subsequent.Ch: 2542case RegexNodeKind.Notonelazy or RegexNodeKind.Notoneloop or RegexNodeKind.Notoneloopatomic when subsequent.M > 0 && node.Ch == subsequent.Ch: 2543case RegexNodeKind.Setlazy or RegexNodeKind.Setloop or RegexNodeKind.Setloopatomic when subsequent.M > 0 && !RegexCharClass.CharInClass(node.Ch, subsequent.Str!): 2544case RegexNodeKind.Multi when node.Ch != subsequent.Str![0]: 2546case RegexNodeKind.EndZ or RegexNodeKind.Eol when node.Ch != '\n': 2547case RegexNodeKind.Boundary when node.M > 0 && RegexCharClass.IsBoundaryWordChar(node.Ch): 2548case RegexNodeKind.NonBoundary when node.M > 0 && !RegexCharClass.IsBoundaryWordChar(node.Ch): 2549case RegexNodeKind.ECMABoundary when node.M > 0 && RegexCharClass.IsECMAWordChar(node.Ch): 2550case RegexNodeKind.NonECMABoundary when node.M > 0 && !RegexCharClass.IsECMAWordChar(node.Ch): 2553case RegexNodeKind.Onelazy or RegexNodeKind.Oneloop or RegexNodeKind.Oneloopatomic when subsequent.M == 0 && node.Ch != subsequent.Ch: 2554case RegexNodeKind.Notonelazy or RegexNodeKind.Notoneloop or RegexNodeKind.Notoneloopatomic when subsequent.M == 0 && node.Ch == subsequent.Ch: 2555case RegexNodeKind.Setlazy or RegexNodeKind.Setloop or RegexNodeKind.Setloopatomic when subsequent.M == 0 && !RegexCharClass.CharInClass(node.Ch, subsequent.Str!): 2568case RegexNodeKind.One when node.Ch == subsequent.Ch: 2569case RegexNodeKind.Onelazy or RegexNodeKind.Oneloop or RegexNodeKind.Oneloopatomic when subsequent.M > 0 && node.Ch == subsequent.Ch: 2570case RegexNodeKind.Multi when node.Ch == subsequent.Str![0]: 2574case RegexNodeKind.Onelazy or RegexNodeKind.Oneloop or RegexNodeKind.Oneloopatomic when subsequent.M == 0 && node.Ch == subsequent.Ch: 2587case RegexNodeKind.One when !RegexCharClass.CharInClass(subsequent.Ch, node.Str!): 2589case RegexNodeKind.Onelazy or RegexNodeKind.Oneloop or RegexNodeKind.Oneloopatomic when subsequent.M > 0 && !RegexCharClass.CharInClass(subsequent.Ch, node.Str!): 2600case RegexNodeKind.Onelazy or RegexNodeKind.Oneloop or RegexNodeKind.Oneloopatomic when subsequent.M == 0 && !RegexCharClass.CharInClass(subsequent.Ch, node.Str!): 2634case RegexNodeKind.One when !CharInStartingOrEndingSet(subsequent.Ch): 2636case RegexNodeKind.Onelazy or RegexNodeKind.Oneloop or RegexNodeKind.Oneloopatomic when subsequent.M > 0 && !CharInStartingOrEndingSet(subsequent.Ch): 2647case RegexNodeKind.Onelazy or RegexNodeKind.Oneloop or RegexNodeKind.Oneloopatomic when subsequent.M == 0 && !CharInStartingOrEndingSet(subsequent.Ch): 3138if (child.Ch >= 128 || 3139RegexCharClass.ParticipatesInCaseConversion(child.Ch)) 3144vsb.Append(child.Ch); 3304Str = new string(Ch, max); 3515sb.Append(" '").Append(RegexCharClass.DescribeChar(Ch)).Append('\'');
System\Text\RegularExpressions\RegexNodeKind.cs (8)
16/// <remarks>The character is specified in <see cref="RegexNode.Ch"/>.</remarks> 19/// <remarks>The character is specified in <see cref="RegexNode.Ch"/>.</remarks> 31/// The character is specified in <see cref="RegexNode.Ch"/>, the minimum number of iterations in <see cref="RegexNode.M"/>, and the maximum number of iterations in <see cref="RegexNode.N"/>. 36/// <remarks>The character is specified in <see cref="RegexNode.Ch"/>, the minimum number of iterations in <see cref="RegexNode.M"/>, and the maximum number of iterations in <see cref="RegexNode.N"/>.</remarks> 45/// <remarks>The character is specified in <see cref="RegexNode.Ch"/>, the minimum number of iterations in <see cref="RegexNode.M"/>, and the maximum number of iterations in <see cref="RegexNode.N"/>.</remarks> 49/// <remarks>The character is specified in <see cref="RegexNode.Ch"/>, the minimum number of iterations in <see cref="RegexNode.M"/>, and the maximum number of iterations in <see cref="RegexNode.N"/>.</remarks> 59/// The character is specified in <see cref="RegexNode.Ch"/>, the minimum number of iterations in <see cref="RegexNode.M"/>, and the maximum number of iterations in <see cref="RegexNode.N"/>. 65/// The character is specified in <see cref="RegexNode.Ch"/>, the minimum number of iterations in <see cref="RegexNode.M"/>, and the maximum number of iterations in <see cref="RegexNode.N"/>.
System\Text\RegularExpressions\RegexPrefixAnalyzer.cs (11)
112case RegexNodeKind.One or RegexNodeKind.Oneloop or RegexNodeKind.Onelazy or RegexNodeKind.Oneloopatomic when !ignoreCase || !RegexCharClass.ParticipatesInCaseConversion(node.Ch): 117sb.Append(node.Ch, reps); 423vsb.Append(node.Ch); 435vsb.Append(node.Ch, count); 603string setString = RegexCharClass.OneToStringClass(node.Ch); 611string setString = RegexCharClass.OneToStringClass(node.Ch); 958cc.AddChar(node.Ch); 967if (node.Ch > 0) 970cc.AddRange((char)0, (char)(node.Ch - 1)); 972if (node.Ch < char.MaxValue) 975cc.AddRange((char)(node.Ch + 1), char.MaxValue);
System\Text\RegularExpressions\RegexReplacement.cs (1)
55vsb.Append(child.Ch);
System\Text\RegularExpressions\RegexWriter.cs (3)
383Emit((RegexOpcode)node.Kind | bits, node.Ch); 395RegexOpcode.Onerep : RegexOpcode.Notonerep) | bits, node.Ch, node.M); 399Emit((RegexOpcode)node.Kind | bits, node.Ch, node.N == int.MaxValue ? int.MaxValue : node.N - node.M);
System\Text\RegularExpressions\Symbolic\RegexNodeConverter.cs (3)
58result.AddLast(_builder.CreateSingleton(_builder._charSetSolver.CreateBDDFromChar(node.Ch))); 62result.AddLast(_builder.CreateSingleton(_builder._solver.Not(_builder._charSetSolver.CreateBDDFromChar(node.Ch)))); 112BDD bdd = _builder._charSetSolver.CreateBDDFromChar(node.Ch);