A combination of Cast and Slice leads to AccessViolationException #674
Labels
bug 🐛
An unexpected issue that highlights incorrect behavior
Good first issue 💯
Issues identified as good for first-time contributors
high-performance 🚂
Issues/PRs for the HighPerformance package
Describe the bug
The following code throws
System.AccessViolationException
:Regression
No response
Steps to reproduce
Expected behavior
The code is supposed to calculate a sum of all values in the slice (in this case, 0).
Screenshots
IDE and version
VS 2022
IDE version
17.4.4
Nuget packages
Nuget package version(s)
8.2.0
Additional context
The problem disappears when there's no
Cast()
(so, we are summing over aSpan
of bytes). It also disappears when there's noSlice()
(so, we are summing overdata
instead ofslice
).Help us help you
No, just wanted to report this
The text was updated successfully, but these errors were encountered: