global semantic refactoring