move duplicated binding generator visitor to it's own class

Resolves #1082.
It has a minor addition to `PrivateModule` so I used a name that resembles it. What do you want me to call it?