Speaking as a C# developer:
I do consider C# more verbose than the languages I love to look at. Think 'SelectMany', 'FirstOrDefault' and similar constructs - even if you write functional C# as much as possible, it still .. is verbose. If compared to F#, Clojure for example.
I don't think that's an issue, mostly, but that I do agree with the notion that C# is 'verbose'.
> Do you have any examples?
Sure, write a self-executing function in C#.
Re:More functional C#
by paulmcpazzi on Monday January 13, 2014 @09:12AM
(#7050604)
((Action)(() => Console.WriteLine("Hello")))();
or new Action(() => Console.WriteLine("Hello"))();
Yeah, it's verbose because you have to cast the lambda expression before executing it, but honestly I don't know any case where a self executing function can be useful in C#.Not too bad. Actions return null though. How about a self-executing function that returns a value? This is useful for assigning values to variables. IIRC it's going to start getting more ugly from here.
Re:More functional C#
by noblethrasher on Monday January 13, 2014 @10:45AM
(#7051183)
(new Func<int>(() => 2))();
I never got the verbosity argument. Verbosity comes down to the person using the language. With C#, you can be as verbose as you want to. Do you have any examples?
What kind of inefficiency are you speaking of? the CLR's GC is one of, if not the, most efficient around.
[0] http://msdn.microsoft.com/en-gb/roslyn