1 instantiation of RegexMethod
System.Text.RegularExpressions.Generator (1)
RegexGenerator.cs (1)
85RegexMethod regexMethod = new(method.DeclaringType, method.IsProperty, method.MemberName, method.Modifiers, method.NullableRegex, method.Pattern, method.Options, method.MatchTimeout, regexTree, analysis, method.CompilationData);
24 references to RegexMethod
System.Text.RegularExpressions.Generator (24)
RegexGenerator.cs (12)
85RegexMethod regexMethod = new(method.DeclaringType, method.IsProperty, method.MemberName, method.Modifiers, method.NullableRegex, method.Pattern, method.Options, method.MatchTimeout, regexTree, analysis, method.CompilationData); 108if (state is not RegexMethod regexMethod) 110Debug.Assert(state is Diagnostic or ValueTuple<RegexMethod, string, Diagnostic, CompilationData>); 139else if (result is ValueTuple<RegexMethod, string, Diagnostic, CompilationData> limitedSupportResult) 193var emittedExpressions = new Dictionary<(string Pattern, RegexOptions Options, int? Timeout), RegexMethod>(); 202RegexMethod? regexMethod = null; 203if (result is ValueTuple<RegexMethod, string, CompilationData> limitedSupportResult) 207else if (result is ValueTuple<RegexMethod, string, Dictionary<string, string[]>, CompilationData> regexImpl) 223if (emittedExpressions.TryGetValue(key, out RegexMethod? implementation)) 264if (result is ValueTuple<RegexMethod, string, CompilationData> limitedSupportResult) 272else if (result is ValueTuple<RegexMethod, string, Dictionary<string, string[]>, CompilationData> regexImpl) 339private static bool SupportsCodeGeneration(RegexMethod method, LanguageVersion languageVersion, [NotNullWhen(false)] out string? reason)
RegexGenerator.Emitter.cs (12)
61private static void EmitRegexPartialMethod(RegexMethod regexMethod, IndentedTextWriter writer) 118IndentedTextWriter writer, RegexMethod rm, string reason, LanguageVersion langVer) 152IndentedTextWriter writer, RegexMethod rm, string runnerFactoryImplementation, bool allowUnsafe) 232private static void EmitRegexDerivedTypeRunnerFactory(IndentedTextWriter writer, RegexMethod rm, Dictionary<string, string[]> requiredHelpers, bool checkOverflow) 752private static (bool NeedsTryFind, bool NeedsTryMatch) EmitScan(IndentedTextWriter writer, RegexMethod rm) 838private static void EmitTryFindNextPossibleStartingPosition(IndentedTextWriter writer, RegexMethod rm, Dictionary<string, string[]> requiredHelpers, bool checkOverflow) 1588private static void EmitTryMatchAtCurrentPosition(IndentedTextWriter writer, RegexMethod rm, Dictionary<string, string[]> requiredHelpers, bool checkOverflow) 5021private static void EmitTimeoutCheckIfNeeded(IndentedTextWriter writer, RegexMethod rm, bool appendNewLineIfTimeoutEmitted = true) 5577private static string DescribeNode(RegexNode node, RegexMethod rm) 5620private static string DescribeCapture(int capNum, RegexMethod rm) 5751private static void DescribeExpressionAsXmlComment(TextWriter writer, RegexNode node, RegexMethod rm, int depth = 0) 5821private static string DescribeLoop(RegexNode node, RegexMethod rm)