API function to check whether one type fits "in" another