Tag: csharp
72 posts · Page 2 of 8
2025-04-09 csharp-14csharpdotnet
C# 14: Simplified parameters with modifiers in lambdas
C# 14 allows using ref, out, in, scoped, and ref readonly modifiers on implicitly typed lambda parameters, eliminating the need to explicitly declare parameter types.
2025-04-08 csharp-14csharpdotnet
Partial constructors and events in C# 14
C# 14 lets you declare instance constructors and events as partial members, splitting definitions across files for cleaner code generation and separation of concerns.
2025-04-07 csharp-14csharpdotnet
C# 14: nameof support for unbound generic types
C# 14 enhances the nameof expression to support unbound generic types like List<> and Dictionary<,>, eliminating the need for placeholder type arguments.
2025-04-06 csharp-14csharpdotnet
Implicit Span conversions in C# 14 – First-class support for Span and ReadOnlySpan
C# 14 adds built-in implicit conversions between Span, ReadOnlySpan, arrays, and strings, enabling cleaner APIs, better type inference, and fewer manual AsSpan() calls.
2025-04-05 csharp-14csharpdotnet
C# 14 – The field keyword and field-backed properties
C# 14 introduces the field contextual keyword for property accessors, letting you add custom logic to auto-properties without declaring a separate backing field.
2025-01-06 csharpdotnetdotnet-9
.NET Performance: ToList vs ToArray
.NET 9 significantly improves ToArray performance using InlineArray, making it faster and more memory-efficient than ToList. See benchmarks comparing .NET 8 vs .NET 9.
2025-01-02 csharp-13csharpdotnet
C# 13: Use params collections with any recognized collection type
C# 13 extends the params modifier beyond arrays to support Span, ReadOnlySpan, IEnumerable, and other collection types, reducing boilerplate and improving flexibility.
2025-01-01 csharp-13csharpdotnet
How to switch to C# 13
How to fix 'Feature is not available in C# 12.0' and switch your project to C# 13 by changing the target framework or setting LangVersion in your .csproj file.
2024-12-01 csharp-14csharpdotnet
What’s new in C# 14.0
A summary of all new features in C# 14.0, including the field keyword, extension members, null-conditional assignment, implicit span conversions, and more.
2024-12-01 csharpdotnet
C# language version history
The evolution of C# has transformed it into a modern, high-performance language. This guide tracks every major milestone. The Early Years (C# 1.0 – 1.2) C# launched in 2002 as a primary language for the .NET Framework. It felt like Java but with a focus on Windows development. Version 1.2 arrived shortly after with small…