October 17th, 2011
(written by lawrence krubner, however indented passages are often quotes). You can contact lawrence at: email@example.com
But despite all that experience, I conclude that writing Haskell code is hard. I don’t mean that in the “math is hard, let’s give up”, sense, but that getting from an empty page to a program that does the job is a harder process than it is with e.g. Perl. A resulting correct Haskell program is likely more reliable, maintainable, and perhaps faster, but getting to that point (framing your problem the right way, knowing how to profile or deal with space leaks, understanding when unsafePerformIO is actually the right thing) is just too much effort.
If you’ve written a Haskell program that runs, it’s highly likely to be a correct solution; but the set of runnable Haskell programs is much smaller than the space of programs that get the job done, and frequently I’m more interested in being done.
I find myself digging up Haskell sometimes for when I want sketch something out mathematically: writing a program to answer a question like “how many different ways can I seat n people at m tables given these extra constraints?” is a delight in Haskell. But for the sorts of code I write, those parts are the small ones; the bigger ones are parsing file formats when the input language is not well specified or interacting with some grungy library.
(That point is the only point I wanted to make, but since there’s nowhere else to shove it in, I’ll add: I also recently dug up some old Haskell code I’d written in the past and found I was unable to compile it due to the “DLL hell” that is package versioning of Hackage. It made me grumpy.)
So, Haskell, I conclude: it was definitely worth my time, even if it had only been so I can understand PL research papers. I can wholeheartedly endorse you learning it as well. But I’m sad to say I don’t imagine myself basing a new major project (or company) around it.