Abstract
Refactoring is a popular technique for improving the structure of existing programs while maintaining their behavior. For statically typed programming languages such as Java, a wide variety of refactorings have been described, and tool support for performing refactorings and ensuring their correctness is widely available in modern IDEs. For the JavaScript programming language, however, existing refactoring tools are less mature and often unable to ensure that program behavior is preserved. Refactoring algorithms that have been developed for statically typed languages are not applicable to JavaScript because of its dynamic nature. We propose a framework for specifying and implementing JavaScript refactorings based on pointer analysis. We describe novel refactorings motivated by best practice recommendations for JavaScript programming, and demonstrate how they can be described concisely in terms of queries provided by our framework. Experiments performed with a prototype implementation on a suite of existing applications show that our approach is well-suited for developing practical refactoring tools for JavaScript.
Original language | English |
---|---|
Title of host publication | Proceedings of the 2011 ACM international conference on Object oriented programming systems languages and applications |
Number of pages | 20 |
Publisher | Association for Computing Machinery |
Publication date | 2011 |
Pages | 119-138 |
ISBN (Print) | 978-1-4503-0940-0 |
DOIs | |
Publication status | Published - 2011 |
Event | 2011 ACM International Conference on Object Oriented Programming Systems Languages and Applications. OOPSLA '11 - Portland, Oregon, United States Duration: 22 Oct 2011 → 27 Oct 2011 |
Conference
Conference | 2011 ACM International Conference on Object Oriented Programming Systems Languages and Applications. OOPSLA '11 |
---|---|
Country/Territory | United States |
City | Portland, Oregon |
Period | 22/10/2011 → 27/10/2011 |