use type inheritance