Unify duplicate typesymbol checking.