Non-Boxing Union Types Feature in C# 15
C# 15's non-boxing union types reduce GC pressure, improving performance in high-volume scenarios.
The Union Types feature in C# 15 (dotnet 11) preview allows for custom user-defined union types that avoid boxing struct values, reducing unnecessary GC pressure in high-volume scenarios. The updated source generator facilitates the creation of these union types without boxing, enhancing performance.
This synthesis was produced from its source by AI; there is no human editor or manual review step. How we work