Back to Search
Start Over
One tool, many languages: language-parametric transformation with incremental parametric syntax
- Source :
- Proceedings of the ACM on Programming Languages. 2:1-28
- Publication Year :
- 2018
- Publisher :
- Association for Computing Machinery (ACM), 2018.
-
Abstract
- We present a new approach for building source-to-source transformations that can run on multiple programming languages, based on a new way of representing programs called incremental parametric syntax. We implement this approach in Haskell in our Cubix system, and construct incremental parametric syntaxes for C, Java, JavaScript, Lua, and Python. We demonstrate a whole-program refactoring tool that runs on all of them, along with three smaller transformations that each run on several. Our evaluation shows that (1) once a transformation is written, little work is required to configure it for a new language (2) transformations built this way output readable code which preserve the structure of the original, according to participants in our human study, and (3) our transformations can still handle language corner-cases, as validated on compiler test suites.
- Subjects :
- FOS: Computer and information sciences
D.3.4
D.3.1
Computer science
02 engineering and technology
computer.software_genre
JavaScript
01 natural sciences
0103 physical sciences
0202 electrical engineering, electronic engineering, information engineering
Safety, Risk, Reliability and Quality
computer.programming_language
010302 applied physics
Computer Science - Programming Languages
Syntax (programming languages)
Programming language
Program transformation
020207 software engineering
Construct (python library)
Python (programming language)
Code refactoring
Haskell
Compiler
computer
Software
Programming Languages (cs.PL)
Subjects
Details
- ISSN :
- 24751421
- Volume :
- 2
- Database :
- OpenAIRE
- Journal :
- Proceedings of the ACM on Programming Languages
- Accession number :
- edsair.doi.dedup.....254111db129b51d97b05e0c21b34aead
- Full Text :
- https://doi.org/10.1145/3276492