Re:Update to the .NET Language Strategy
by CharlieDigital on Thursday February 09, 2023 @07:15AM
(#34722820)
Start a petition for T#.
Merge C# and TypeScript.
I want my C# pattern matching in TypeScript and TypeScript's fluidity in C#.
Simplified initialization in C# without new(). Unless otherwise specified, use a default generic Dictionary<T,U> and infer the types for map initialization like:
var x = { ["a"] = 1 };
Instead of:
var x = new Dictionary<string,int> {...};
Then automatic type mapping and conversion utilities to objects:
record class Rec(string a, int val);
var k = x as (Rec)
(Yes, can already be done with implicit type conversion operators or writing utility classes, but making it more like TypeScript would just make it easier to adopt)
Merge C# and TypeScript.
I want my C# pattern matching in TypeScript and TypeScript's fluidity in C#.
Simplified initialization in C# without new(). Unless otherwise specified, use a default generic Dictionary<T,U> and infer the types for map initialization like:
Instead of: Then automatic type mapping and conversion utilities to objects: (Yes, can already be done with implicit type conversion operators or writing utility classes, but making it more like TypeScript would just make it easier to adopt)