Fix ICE generating unboxed closure type visitor glue

This is a quick fix.  In the long term, the `TyVisitor` interface should be expanded to better represent closure types.

Closes issue #17737