Type system design