[hacc] Reorganize and improve type instantiation
[hacc] Fix forgotten break in switch