Re:Swift and the Legacy of Functional Programming
by imh on Monday November 21, 2016 @04:40PM
(#13009475)
You're 100% right about debugability. It's the main reason I don't push to use haskell every day. That said, I think we really need to get clever and think of good tools to debug in spite of these difficulties. Most complex bugs are from interacting systems that can't be found by step debugging. For example, the following code is considered pythonic, and for good reason:
fs = [f(x) for x in xs]
The other commenter's points about being cleaner and less prone to debugging are totally legit. If we can make e.g. list/set comprehensions debuggable, we can probably make other FP idioms debuggable and get the best of both worlds.
Kinda reminds me of microservices, actually. Tough to debug, but good in other ways.
Kinda reminds me of microservices, actually. Tough to debug, but good in other ways.