Removes dead references from project.