Fundamentals - Part 19
Records are C#'s built-in value-semantics types for modeling data. They look like classes, but the compiler wires up value equality, deconstruction, and with expressions for you. That power is great when you want immutable "data carriers", and risky when you treat them like mutable objects. This post explains where records help, where they hurt, and how to control the generated members.









