basic rewrite of internal type representation.