RegexGenerator.Emitter.cs (38)
655using (EmitBlock(writer, "if (TryFindNextPossibleStartingPosition(inputSpan))"))
673using (EmitBlock(writer, "if (TryFindNextPossibleStartingPosition(inputSpan) && !TryMatchAtCurrentPosition(inputSpan))"))
699using (EmitBlock(writer, null))
746clause = EmitBlock(writer, (minRequiredLength, rtl) switch
834using (EmitBlock(writer, "if (pos == 0)"))
850using (EmitBlock(writer, "if (pos == base.runtextstart)"))
861using (EmitBlock(writer, "if (pos < inputSpan.Length - 1)"))
873using (EmitBlock(writer, "if (pos < inputSpan.Length)"))
885using (EmitBlock(writer, "if (pos != 0)"))
898using (EmitBlock(writer, "if (pos >= inputSpan.Length - 1 && ((uint)pos >= (uint)inputSpan.Length || inputSpan[pos] == '\\n'))"))
908using (EmitBlock(writer, "if (pos >= inputSpan.Length)"))
919using (EmitBlock(writer, $"if (pos < inputSpan.Length - {regexTree.FindOptimizations.MinRequiredLength + 1})"))
930using (EmitBlock(writer, $"if (pos < inputSpan.Length - {regexTree.FindOptimizations.MinRequiredLength})"))
949using (EmitBlock(writer, "if (pos > 0 && inputSpan[pos - 1] != '\\n')"))
952using (EmitBlock(writer, "if ((uint)newlinePos > inputSpan.Length - pos - 1)"))
961using (EmitBlock(writer, minRequiredLength switch
980using (EmitBlock(writer, $"if (pos < inputSpan.Length - {maxLength})"))
989using (EmitBlock(writer, $"if (pos < inputSpan.Length - {maxLength + 1})"))
1055using (EmitBlock(writer, "if (i >= 0)"))
1112using (EmitBlock(writer, "if (i >= 0)"))
1127using (EmitBlock(writer, "if (pos >= 0)"))
1166loopBlock = EmitBlock(writer, $"for (int i = 0; i < {upperBound}; i++)");
1238using (EmitBlock(writer, "if (indexOfPos < 0)"))
1261using (EmitBlock(writer, $"if ((uint)(i + {maxDistance}) >= (uint)span.Length)"))
1273using (EmitBlock(writer, "if (i >= 0)"))
1312using (hasCharClassConditions ? EmitBlock(writer, null) : default)
1338using (EmitBlock(writer, "if (pos >= 0)"))
1346using (EmitBlock(writer, "while ((uint)--pos < (uint)inputSpan.Length)"))
1348using (EmitBlock(writer, $"if ({MatchCharacterClass("inputSpan[pos]", set.Set, negate: false, additionalDeclarations, requiredHelpers)})"))
1382block = EmitBlock(writer, "while (true)");
1404using (EmitBlock(writer, $"if (i < 0)"))
1412indexOfFoundBlock = EmitBlock(writer, $"if (i >= 0)");
1417using (EmitBlock(writer, $"while ((uint)prev < (uint)slice.Length && {MatchCharacterClass("slice[prev]", target.LoopNode.Str!, negate: false, additionalDeclarations, requiredHelpers)})"))
1427using (EmitBlock(writer, $"if ((i - prev - 1) < {target.LoopNode.M})"))
1635using (EmitBlock(writer, $"if ({SpanLengthCheck(requiredLength, dynamicRequiredLength)})"))
1784using (EmitBlock(writer, $"switch ({sliceSpan}[{sliceStaticPos}])"))
1970using (EmitBlock(writer, $"// Branch {i}", faux: !isAtomic))
4904using (rm.MatchTimeout is null ? EmitBlock(writer, $"if ({HelpersTypeName}.{HasDefaultTimeoutFieldName})") : default)