Recognizers-Text
Recognizers-Text copied to clipboard
[* DateTime V2] Refactor Timex parsing code to use Spans instead of Strings
Replace String manipulation operations in TImexUtility with more efficient Span manipulation operations.
For example: var subStr = inputStr.Substring(start, length); --> var subSpan = inputSpan.Slice(start, length);
@tellarin, I left a comment in #2950 about this.
It seems that parsing of spans is not supported in .NET Framework, so the span needs to be converted back to string when passing it to int.TryParse. Should we still proceed? Or do you have other suggestions?