C# has evolved significantly over time, from version 1 through the latest version 8. Some key developments include the addition of generics, LINQ, asynchronous programming, and dynamic features. C# continues to focus on productivity and safe, efficient code with recent versions adding capabilities like nullable reference types, async streams, and ranges/indices. .NET has also evolved with improvements to performance and new functionality in versions like .NET Core 2.1. Looking ahead, .NET Core 3 will add support for desktop frameworks like WinForms and WPF.
6. C# 7.0, 7.1, 7.2 and 7.3
• Safe, efficient code
• Avoid garbage collection
• Avoid copying
• Stay safe
• More freedom
• Allow more things
• Less code
• Say it shorter
23. Safe efficient code enhancements
• Work with value types while using reference semantics
• in
• ref readonly
• readonly struct
• ref struct
24. Non-trailing named arguments
Named arguments that precede positional arguments when
those named arguments are in the correct positions
PrintOrderDetails("Gift Shop", 31, "Red Mug")
PrintOrderDetails(sellerName: "Gift Shop", 31, productName: "Red Mug");
PrintOrderDetails(productName: "Red Mug", sellerName: "Gift Shop", orderNum: 31)
25. private protected access modifier
A new compound access modifier:
private protected
Indicates that a member may be accessed by containing
class or derived classes that are declared in the same
assembly.
27. Enabling more efficient safe code
• Access fixed fields without pinning
• Reassign ref local variables
• Initializers on stackalloc arrays
• Fixed statements with any type that supports a pattern
• Additional generic constraints
28. Make existing features better
• Operators == and != with tuple types
• Expression variables in more locations
• Attach attributes to the backing field of auto-
implemented properties
• Method resolution when arguments differ by in has been
improved
• Overload resolution now has fewer ambiguous cases
29. New compiler options
• New compiler options support new build and DevOps
scenarios
• -publicsign to enable Open Source Software (OSS) signing of
assemblies.
• -pathmap to provide a mapping for source directories.
41. .NET Core 2.1
• Faster Build & Runtime Performance
• Close gaps in ASP.NET Core and EF Core
• Improve compatibility with .NET Framework
• GDPR and Security
• Microservices and Azure
• Faster Internal Engineering System
48. .NET Core 3
• Focus in the Desktop:
• Supports WinForms and WPF frameworks
• Access to all the Windows 10 API’s
49. Why Windows Desktop on .NET Core?
• Side-by-side versions of .NET that support WinForms and
WPF
• Embed .NET directly into an application:
• Take advantage of .NET Core features
50. .NET Framework 4.8
• Focus in the Desktop too!
• Modern browser and modern media controls
• Access to touch and UWP Controls
• High DPI improvements
51. Highly-compatible,
targeted improvements,
like last few releases
• XAML Islands - WinForms & WPF apps
can host UWP controls
• HDPI and accessibility improvements
• .NET Framework support unchanged
(supported for life of Windows)
• XAML Islands - WinForms & WPF apps can host UWP controls
• Full access to Windows 10 APIs
• Side-by-side support & self contained exes
• Desktop pack to enable porting existing apps
to .NET Core
UWP
Windows-only
DATAWEB
ASP.NET
Core
EF Core
AI/ML
ML.NET
WPF
.NET Core 3Desktop Packs.NET Framework 4.8
.NET STANDARD
Existing App
Highly
compatible
updates
.NET Core
3.0 with
Desktop
Packs
Install .NET
Core updates
per your
needs
Modernize Desktop Apps with .NET Core 3
Windows-only
.NET STANDARD
Cross-platform
Windows
Forms
Update .NET Framework Apps
EF6 (cross-plat)