You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucenenet.apache.org by GitBox <gi...@apache.org> on 2022/10/15 19:30:46 UTC

[GitHub] [lucenenet] nikcio opened a new issue, #675: Prefer 'AsSpan' over 'Substring' when span-based overloads are available

nikcio opened a new issue, #675:
URL: https://github.com/apache/lucenenet/issues/675

   Mentioned in #648 
   
   Issues found: https://sonarcloud.io/project/issues?resolved=false&rules=external_roslyn%3ACA1846&id=nikcio_lucenenet
   
   We can conditionally reference the package [System.Memory](https://www.nuget.org/packages/System.Memory) in `net462` and `netstandard2.0` to fix this. Other targets don't need to reference the package. No comment needed. This is more efficient and is understood to be a better translation from Java to .NET. Do note the overload of `Substring(int, int)` differs between Java (second parameter is `end`) and .NET (second parameter is `length`. To correct use `length = end - start`. We should have done this already.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@lucenenet.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [lucenenet] NightOwl888 closed issue #675: Prefer 'AsSpan' over 'Substring' when span-based overloads are available

Posted by GitBox <gi...@apache.org>.
NightOwl888 closed issue #675: Prefer 'AsSpan' over 'Substring' when span-based overloads are available
URL: https://github.com/apache/lucenenet/issues/675


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@lucenenet.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org