The behaviour of `collectTyAndValBinders` is missleading.
Naively I would have expected
collectTyAndValBinders to strip of all leading lambdas of an expression.
It's however not what it does unless all type variables come first. The reason for this is that it first strips of as sequential type variables as it can, then as many sequential value binders as it can, and then it declares it's job done.
However if we have something like:
foo = \x @A y @B z -> e it would only return
x as lone value binder and zero type binders.
There are only two use sites of this so the impact isn't big and in both cases it seems like we would only optimize worse than expect. But we should probably look at all binders and split them into ty/val binders as we go instead of expecting a strict "types first, values after" order.