#Immutability
2 notas · última:
There and Back Again
The author compares C# and F# through a bank-account withdrawal app, showing how immutability in F# keeps data changes separate from persistence, while C# needs extra care with Entity Framework tracking.
Everything You Want to Know About the Record Type in .NET… But Were Afraid to Ask
The article presents record types in .NET 5 as a fit for model types such as DTOs and POCOs, with less boilerplate and built-in support for immutability. It also notes that records generate equality members, GetHashCode(), and a useful ToString(), while mentioning a custom PropertiesToString() for collection properties.
