You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Ilchert
changed the title
Incorrect comparation in InlineArray records
Record structs with InlineArray attribute compares only by the first value.
May 16, 2024
This combination of features (record and InlineArray) is not particularly useful. @AlekseyTs did we consider making this combination an error at declaration? Can't see any good reasons to allow this.
Related to the dotnet/runtime/issues/96943.
Version Used:
dotnet SDK 8.0.204
Steps to Reproduce:
record struct
withInlineArray
attributeInlineArray
attribute compares only by the first value.sharplab
Expected Behavior:
Should compare all values in inline array and print false in this case.
Actual Behavior:
Compares only the first element.
The text was updated successfully, but these errors were encountered: