Skip to content

StorageObject: can it be made "record" instead of a class #21

Description

@benrussill

If the values are not going to be changed after creation, then using a ** record struct **, and potentially even ** readonly record struct ** if data is immutable. The reason for doing this is that Object.Equals compares the values of the record, and not the reference.

Records (C# reference) - value equality

Records: Immutability

Record Struct c# 10

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions