News for hackers. Stuff that matters.
Re:Dart language by olavk on Monday October 10, 2011 @09:14AM (#3093613)
Well, if your example were meant seriously, it is needlessly verbose. ToList is not necessary in this context, and the type arguments to ToList and FirstOrDefault are not necessary since they can be inferred. And anyway, you can just insert line breaks if you think the chain is too long. So:

    grain.OfType<Salt>()
          .Where(m => m.Value.Contains(nothing))
          .OrderBy(m => m.irrelevance)
          .FirstOrDefault();
I don't really get your verbosity criticism, sine any alternative I can think of (eg. using for loops) is much more verbose.

There are no comments on this comment yet.