support polymorphic types.