Initial implementation of struct-type contract generation.

Good point. This implies that we can do better for `VectorTop` etc as well.