title: How to debug Haskell code?
body: <p>I have a problem. I wrote a big Haskell program, and it always works with small input. Now, when I want to test it and generate a bigger input, I always get the message:</p>
  
  <pre><code>HsProg: Prelude.head: empty list
  </code></pre>
  
  <p>I use <code>Prelude.head</code> many times. What can I do to find out more or get a better error output to get the code line in which it happens?</p>