A meta-model for language-independent refactoring

Sander Tichelaar, Sté́phane Ducasse, Serge Demeyer, Oscar Nierstrasz

2002 · 89 citations · 8 references

Concepts

TL;DR

Refactoring preserves behaviour and improves object‑oriented systems, but existing tools are language‑dependent, hindering integration with mainstream environments. The study aims to derive a language‑independent meta‑model for refactoring and demonstrate the feasibility of a universal refactoring engine. The authors validated the meta‑model by prototyping a single engine that refactors both Smalltalk and Java code. The approach reduces language dependence in refactoring tools, enabling a standard, language‑agnostic refactoring workflow.

Abstract

Refactoring-transforming code while preserving behaviour-is considered a key approach for improving object-oriented software systems. Unfortunately, all of the current refactoring tools depend on language-dependent refactoring engines, which prevents a smooth integration with mainstream development environments. We investigate the similarities between refactorings for Smalltalk and Java, derive a language-independent meta-model and show that it is feasible to build a language-independent refactoring engine on top of this meta-model. Our feasibility study is validated by means of a tool prototype which uses the same engine to refactor both Smalltalk and Java code. Using our approach we minimize the language-dependent part of refactoring tools, providing a standard way for programmers and tools to perform refactorings no matter what language they work in.

References

8