UML class diagrams are usually annotated with OCL expressions that constrain their possible instantiation. In our work we have investigated how OCL annotations can be automatically updated each time the underlying diagram is refactored. All our refactoring rules are formally specified using a QVT-based graphical formalism and have been implemented in our tool ROCLET. I. REFACTORING CLASS DIAGRAMS In this section we give a motivation for performing UML/ OCL refactorings and show on an example, how OCL constraints have to be treated when the underlying UML class diagram changes. Note that our approach does not aim to improve the structure of OCL expressions in order to get rid of OCL smells (see [1]). We are just concerned about smells in UML class diagrams, how to eliminate these smells by class diagram refactorings, and how to keep the annotated OCL constraints in sync with these changes. Figure 1 shows the application of refactoring MoveAttribute on a class diagram annotated with one ...