News for hackers. Stuff that matters.
Re:New case studies about Google’s use of Go by kevinmgranger on Thursday August 27, 2020 @04:48PM (#24298472)
map/filter and sum types are not about "fun", they're about correctness and expressiveness.

map/filter and their equivalent loops are both perfectly readable, but the latter involves more boilerplate.

Re:New case studies about Google’s use of Go by somethingwitty1 on Thursday August 27, 2020 @06:48PM (#24299532)
And I'd disagree. Numerous engineers of differing skill levels (what I deal with day to day), struggle significantly when map/filter are added into the mix. And we may say "get better engineers", but we don't have that ability. We have to write code that is maintainable for the engineers we have and can get (and the ones coming in the future).
Re:New case studies about Google’s use of Go by Guthur on Thursday August 27, 2020 @08:27PM (#24300233)
Come on, map and filter difficult? That's hyperbole of the highest order.
Re:New case studies about Google’s use of Go by ecnahc515 on Thursday August 27, 2020 @11:10PM (#24301008)
Not really. They require a basic understanding of higher order functions and often heavily use closures. Those moderately advanced concepts. It’s also sometimes harder to write efficiently to avoid multiple iterations over the same collection. I think many many people are way more comfortable with loops than people are with map/filter.
Re:New case studies about Google’s use of Go by hrez on Thursday August 27, 2020 @04:58PM (#24298592)
I'd settle for comprehensions. It already has generic for/range so why not. That would cover a lot of boilerplate annoyances.