remove unused external classes set from RenamingSubstitutionMap