Developer Support

Advocacy and Innovation

Avoiding struct and readonly reference performance pitfalls with ErrorProne.NET

As you may know from my previous posts "The 'in'-modifier and the readonly structs in C#" and "Performance traps of ref locals and ref returns in C#", structs are trickier then you might think. Mutability aside, the behavior of readonly and non-readonly structs in "readonly" contexts is very different. Structs are meant for high-performance...

Feedback usabilla icon