Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Version 1.5 is out with many adjustments made to integrate as flawlessly as possible with .Net 9.
Due to the introduction of variable-length Split methods in .Net 9, our custom Split methods have been replaced as the default by the new versions.
This applies to all .Net versions as for versions prior to .Net 9 a custom implementation approximating the behaviour of the new methods has been provided by this package to ensure a smooth transition.
This decision helps maintain compatibility across .Net versions.
The old Split implementations are however still available as static methods on the
ReadOnlySpanExtensions
andSpanExtensions
classes forReadOnlySpan<T>
andSpan<T>
respectively.They provide a richer set of features with overloads for taking a number of splits and specifiyng a behaviour for when that count is reached.
Uprading Guide:
If you're upgrading from a version earlier than 1.5, beware that in order to access the old implementations you've been using an explicit reference to the class is needed.
So
becomes
Span.Split() refers to the new built-in implementations for which a compatibility layer will be provided for versions before .Net 9 so that their use in your codebase can be facilitated across versions.
The ReadOnlyspanExtensions methods are supported in this version, but will be deprecated as soon as the .Net 9 versions catch up in features.
Full Changelog: https://github.com/draconware-dev/SpanExtensions.Net/blob/main/Changelog.md