modify to drop internally defined types