Blog
Mert Özen's blog posts on software development, backend, frontend, and DevOps.
What's New in .NET 11: Async Validation, OpenAPI 3.2 and C# 15 Union Types in ASP.NET Core
.NET 11 STS brings async validation and localized messages to minimal APIs, [ShortCircuit], C# 15 union types, OpenAPI 3.2 with QUERY and itemSchema, removed APIs and support until 2028-11-14.
What's New in C# 15: Union Types, Closed Hierarchies and Collection Arguments
C# 15 next to its C# 10 and C# 14 equivalents: with(...) for comparers and capacity in collection expressions, union types and the default-value trap, closed hierarchies with exhaustive switches and no default arm, extension indexers, labeled break/continue, static interface members on older runtimes and the memory safety preview.
A Pattern Selection Guide and C# 15: Union Types, Closed Hierarchies and How Patterns Evolve
The way to choose the right pattern is to start from the problem, not the pattern: find what must stay free to vary, then pick a candidate from the creation, wrapping, behavior, state, tree and outcome families. How lambdas, yield, records and pattern matching slimmed patterns down in C#, and how C# 15's union types and closed hierarchies rewrite Visitor, State and Result with exhaustive switches, with real compiler warnings.