Replies: 3 comments 7 replies
-
" Expressions are second class citizens- according to https://github.com/dotnet/corefx/issues/33170 System.Linq.Expressions is archived meaning: "When archived, we would not accept features contributions to the packages. We would consider changes that address significant bugs or regressions, or changes that are necessary to continue shipping the binaries. Other changes will be rejected." several tickets to 'can we please have expressions do this thing also' have been closed as 'won't fix', or have hung for years after that has been pointed out. Could we have a statement from the group on what they consider the position of expressions within the language is, and if expressions are first class or second class citizens? |
Beta Was this translation helpful? Give feedback.
-
Now that you guys have affirmed Action/Func/synthesized delegate as the "natural type" of lambdas, maybe now its time to consider whether a type-only version should be allowed in type positions as well? (A la TypeScript) public (string s, int i) => int Foo()
{
return ( s, i) => 42;
} equivalent to public Func<string, int, int> Foo()
{
return (s, i) => 42;
} Of course this is a little weird given the other C# 10 decision to allow return types on lambdas but put them in the front. Given that, maybe a "type-only" lambda looks more like this? Either way, I think this is worth considering as these anonymous lambdas have more descriptive parameter names and are also more natural to read than Func or Action. |
Beta Was this translation helpful? Give feedback.
-
Why should |
Beta Was this translation helpful? Give feedback.
-
https://github.com/dotnet/csharplang/blob/main/meetings/2021/LDM-2021-05-10.md
Agenda
Beta Was this translation helpful? Give feedback.
All reactions