Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

Haskell core language is really simple. Coming from an OO background, the main difficulty is to adapt to the pure functional paradigm.

While learning "basic" Haskell, I have always considered language extensions as toys for CS people or as experiments for future versions of the language (like from future import ??? in python).

However when I began to look at web frameworks such as Yesod, I find that a lot of source files require between 3 & 4 extensions. Some look quite simple (StringOverload). Other are really intimidating (GADT, Type Famillies, Template Haskell). Their documentation links to research papers, which is scary for someone expecting to learn "just" a new library.

Is it necessary to learn GHC language extensions to be productive in Haskell? If you were to hire a Haskell developer for a production application, would you ask for such knowledge?

share|improve this question
    
See also: stackoverflow.com/a/10849782/894284 –  Matt Fenwick May 10 '13 at 15:46
add comment

1 Answer

up vote 7 down vote accepted

Is it necessary to learn GHC language extensions to be productive in Haskell?

Yes. And that is true for any language/tool. With the core/basic knowledge you can solve the online contest problems, may be small university project, but definitely not real world application.

If you were to hire a haskell developper for a production application, would you ask for such knowledge?

That now depends on do you have some person with you which can share this knowledge. If yes, then that person can ramp up the new employee. If not then you must get such person with knowledge first. And again this is true for new technologies.

Off-course you could also try to hire peoples having such deep knowledge in Haskell. But Haskell being relatively new into industry and considering very few commercial projects have been done around it, finding such person will be hard. The effective way to build a team of professionals in Haskell, will be to hire people who knew basic and willing to work in Haskell, and then educate them.

share|improve this answer
    
I was going to protest, but then I saw that Real World Haskell teaches many language extension. Thank you for your answer. –  Simon May 15 '13 at 15:10
    
"And that is true for any language/tool" - that's completely false. Say, take such languages as Java, C#, C++ - none of them have language extensions which are commonly found in real world applications code. If you have to use language extensions every time you need to write anything less trivial than "the online contest problem solutions", in my opinion, there's something very wrong with the language spec. –  Malcolm Jun 25 '13 at 20:59
    
@Malcolm Why do you find "If you have to use language extensions every time you need to write anything less trivial than "the online contest problem solutions", in my opinion, there's something very wrong with the language spec." to be true? What is the characteristic of an extension that makes it negative? I use ghc and the provided extensions. Adding an extension to an existing project seems just as burdensome as adding another library. –  Davorak Jul 14 '13 at 12:45
    
@Davorak Because instead of a single language we have zillion of different extension combinations, and you don't know anything about whether the code is going to compile on a certain compiler. Extensions make the code non-portable. And also this makes the language a pain to learn because instead of a single set of features which everyone uses there is tremendous amount of additional features, and you haven't got a clue which ones you have to know and use and which ones exist just because researchers are having fun. –  Malcolm Jul 14 '13 at 20:10
    
@Malcolm - I guess my impression about haskell compiles was that pretty much everyone uses ghc unless you are going something specialized so for most people the portability question is not a problem. "instead of a single set of features which everyone uses there is tremendous amount of additional features," <- I guess my impression of this was it was no worse then having to learn multiple libraries and not know which ones are the best to learn. Thanks for detailing your understanding. –  Davorak Jul 15 '13 at 0:02
show 1 more comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.