We present an approach to describing refactorings that abstracts away from particular refactorings to classes of similar transformations, and presents an implementation of these that works by substitution and subsequent rewriting. Substitution is language-independent under this approach, while the rewrites embody language-specific aspects. Intriguingly, it also goes back to work on API migration by Huiqing Li and the first author, and sets refactoring in that general context.
翻译:我们提出了一个描述重构要素的方法,这些要素从特定重构要素到类似变换的类别,并介绍了这些要素的落实情况,这些要素通过替代和随后的重写发挥作用。 替代方法以语言为独立,而重写则体现特定语言的方面。 有趣的是,它又回到了惠青李和第一作者关于API移民问题的工作,并在这一大背景下重新设定了重构因素。