Seems you lack the proper instance of NFData for Foo

instance NFData Foo where
    rnf f = foo f `deepseq` ()

With this change, keeping either line produces outer exception.

On Tue, May 12, 2015 at 10:43 AM Alex <alex323@gmail.com> wrote:
On Tue, 12 May 2015 06:25:44 +0000
Alexey Shmalko <rasen.dubi@gmail.com> wrote:

> Seems, that you're putting it in the wrong place. Please, publish
> your code to lpaste [1].
>
> Hmm.... Maybe you need evaluate `encode req`?
>

I've created a test case demonstrating the behavior which is confusing
me:

http://lpaste.net/132446

--
Alex