Fix code-gen of nested whatever curries.

Makes this construct work on MoarVM, and may be more efficient on
other backends.