Kryptovalutaticker:
sysadmin från The Register

Microsoft devs rejoice: Union types coming to C# in November

13 hours ago
10 Visningar
0 Kommentarer
Microsoft devs rejoice: Union types coming to C# in November

Microsoft is set to launch the next iteration of C# this November. Redmond recently unveiled a preview of C# 15 that introduces tighter restrictions on data types alongside enhanced memory safety protections. Perhaps the most frequently requested feature that arrives with this release is union types. Union types are not new to programming. Python, Scala and TypeScript all recognize the concept. But with C#, “This is how unions should be,” boasted C# lead designer Mads Torgersen in an introductory talk earlier this year. In a nutshell, union types provide a way to categorize different custom data types into a single entity. The union keyword can unite a collection of custom data types (“Dog,” “Cat,” and “Bird”) as a single...

Läs hela artikeln hos källan.

Delta i diskussionen — kommentera, rösta och dela länkar.

Registrera
Var detta hjälpsamt?
Dela:

Kommentarer (0)

Vänligen logga in eller registrera dig för att delta i diskussionen

Inga kommentarer ännu. Bli först med att kommentera!