Compare commits

...

2 Commits

2 changed files with 4 additions and 4 deletions
@@ -14,7 +14,7 @@ internal static class MatcherExtensions
this IMatcher<TContext, TValue> matcher,
TContext context,
StringSegment segment,
Func<TContext, StringSegment, TValue> transformFallback
Func<TContext, StringSegment, TValue> fallbackTransform
)
{
// Loop through segments divided by individual matches
@@ -40,7 +40,7 @@ internal static class MatcherExtensions
yield return new ParsedMatch<TValue>(
fallbackSegment,
transformFallback(context, fallbackSegment)
fallbackTransform(context, fallbackSegment)
);
}
@@ -57,7 +57,7 @@ internal static class MatcherExtensions
yield return new ParsedMatch<TValue>(
fallbackSegment,
transformFallback(context, fallbackSegment)
fallbackTransform(context, fallbackSegment)
);
}
}
@@ -14,5 +14,5 @@ internal readonly record struct StringSegment(string Source, int StartIndex, int
public StringSegment Relocate(Capture capture) => Relocate(capture.Index, capture.Length);
public override string ToString() => Source.Substring(StartIndex, Length);
public override string ToString() => Source[StartIndex..EndIndex];
}