{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2025,7,4]],"date-time":"2025-07-04T21:01:10Z","timestamp":1751662870523,"version":"3.41.0"},"reference-count":56,"publisher":"Association for Computing Machinery (ACM)","issue":"OOPSLA","license":[{"start":{"date-parts":[[2018,10,24]],"date-time":"2018-10-24T00:00:00Z","timestamp":1540339200000},"content-version":"vor","delay-in-days":0,"URL":"https:\/\/creativecommons.org\/licenses\/by\/4.0\/"}],"content-domain":{"domain":["dl.acm.org"],"crossmark-restriction":true},"short-container-title":["Proc. ACM Program. Lang."],"published-print":{"date-parts":[[2018,10,24]]},"abstract":"<jats:p>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.<\/jats:p>","DOI":"10.1145\/3276492","type":"journal-article","created":{"date-parts":[[2018,10,24]],"date-time":"2018-10-24T11:57:18Z","timestamp":1540382238000},"page":"1-28","update-policy":"https:\/\/doi.org\/10.1145\/crossmark-policy","source":"Crossref","is-referenced-by-count":9,"title":["One tool, many languages: language-parametric transformation with incremental parametric syntax"],"prefix":"10.1145","volume":"2","author":[{"given":"James","family":"Koppel","sequence":"first","affiliation":[{"name":"Massachusetts Institute of Technology, USA"}]},{"given":"Varot","family":"Premtoon","sequence":"additional","affiliation":[{"name":"Massachusetts Institute of Technology, USA"}]},{"given":"Armando","family":"Solar-Lezama","sequence":"additional","affiliation":[{"name":"Massachusetts Institute of Technology, USA"}]}],"member":"320","published-online":{"date-parts":[[2018,10,24]]},"reference":[{"volume-title":"Term Rewriting and All That","author":"Baader Franz","key":"e_1_2_2_1_1","unstructured":"Franz Baader and Tobias Nipkow . 1999. Term Rewriting and All That . Cambridge university press . Franz Baader and Tobias Nipkow. 1999. Term Rewriting and All That. Cambridge university press."},{"key":"e_1_2_2_2_1","doi-asserted-by":"publisher","DOI":"10.1145\/2036918.2036930"},{"key":"e_1_2_2_3_1","doi-asserted-by":"publisher","DOI":"10.5555\/998675.999466"},{"key":"e_1_2_2_4_1","doi-asserted-by":"publisher","DOI":"10.1145\/2676726.2676982"},{"key":"e_1_2_2_5_1","volume-title":"language-java: Manipulating Java source: abstract syntax, lexer, parser, and pretty-printer. http: \/\/hackage.haskell.org\/package\/language-java-0.2.8 . (November","author":"Broberg Niklas","year":"2015","unstructured":"Niklas Broberg . 2015. language-java: Manipulating Java source: abstract syntax, lexer, parser, and pretty-printer. http: \/\/hackage.haskell.org\/package\/language-java-0.2.8 . (November 2015 ). Niklas Broberg. 2015. language-java: Manipulating Java source: abstract syntax, lexer, parser, and pretty-printer. http: \/\/hackage.haskell.org\/package\/language-java-0.2.8 . (November 2015)."},{"key":"e_1_2_2_6_1","doi-asserted-by":"publisher","DOI":"10.1145\/2872362.2872364"},{"key":"e_1_2_2_7_1","volume-title":"Schwartz","author":"Brumley David","year":"2011","unstructured":"David Brumley , Ivan Jager , Thanassis Avgerinos , and Edward J . Schwartz . 2011 . BAP : A Binary Analysis Platform. In CAV. David Brumley, Ivan Jager, Thanassis Avgerinos, and Edward J. Schwartz. 2011. BAP: A Binary Analysis Platform. In CAV."},{"volume-title":"Transactions on","author":"Churchill Martin","key":"e_1_2_2_8_1","unstructured":"Martin Churchill , Peter D Mosses , Neil Sculthorpe , and Paolo Torrini . 2015. Reusable Components of Semantic Specifications . In Transactions on Aspect-Oriented Software Development XII. Springer , 132\u2013179. Martin Churchill, Peter D Mosses, Neil Sculthorpe, and Paolo Torrini. 2015. Reusable Components of Semantic Specifications. In Transactions on Aspect-Oriented Software Development XII. Springer, 132\u2013179."},{"key":"e_1_2_2_9_1","doi-asserted-by":"publisher","DOI":"10.1016\/S0304-3975(01)00359-0"},{"key":"e_1_2_2_10_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.scico.2006.04.002"},{"key":"e_1_2_2_11_1","doi-asserted-by":"publisher","DOI":"10.1145\/2804302.2804315"},{"key":"e_1_2_2_12_1","doi-asserted-by":"publisher","DOI":"10.1145\/2500365.2500587"},{"key":"e_1_2_2_14_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.scico.2012.12.002"},{"volume-title":"Introduction to Tornado: Modern Web Applications with Python. O\u2019Reilly Media","author":"Dory Michael","key":"e_1_2_2_15_1","unstructured":"Michael Dory , Allison Parrish , and Brendan Berg . 2012. Introduction to Tornado: Modern Web Applications with Python. O\u2019Reilly Media , Inc . Michael Dory, Allison Parrish, and Brendan Berg. 2012. Introduction to Tornado: Modern Web Applications with Python. O\u2019Reilly Media, Inc."},{"volume-title":"The State of the Art in Language Workbenches. In International Conference on Software Language Engineering. Springer, 197\u2013217","author":"Erdweg Sebastian","key":"e_1_2_2_16_1","unstructured":"Sebastian Erdweg , Tijs van der Storm, Markus V\u00f6lter, Meinte Boersma, Remi Bosman, William R Cook, Albert Gerritsen, Angelo Hulshout, Steven Kelly, Alex Loh, et al. 2013 . The State of the Art in Language Workbenches. In International Conference on Software Language Engineering. Springer, 197\u2013217 . Sebastian Erdweg, Tijs van der Storm, Markus V\u00f6lter, Meinte Boersma, Remi Bosman, William R Cook, Albert Gerritsen, Angelo Hulshout, Steven Kelly, Alex Loh, et al. 2013. The State of the Art in Language Workbenches. In International Conference on Software Language Engineering. Springer, 197\u2013217."},{"key":"e_1_2_2_17_1","volume-title":"CPython Test Suite. Version 3.7.0a0. https:\/\/docs.python.org\/devguide\/runtests.html . (October","author":"Foundation Python Software","year":"2016","unstructured":"Python Software Foundation . 2016. CPython Test Suite. Version 3.7.0a0. https:\/\/docs.python.org\/devguide\/runtests.html . (October 2016 ). Python Software Foundation. 2016. CPython Test Suite. Version 3.7.0a0. https:\/\/docs.python.org\/devguide\/runtests.html . (October 2016)."},{"key":"e_1_2_2_18_1","unstructured":"FSF. 2016. C Language Testsuites: \u201cC-torture\u201d. Revision 240758. http:\/\/gcc.gnu.org\/onlinedocs\/gccint\/C-Tests.html . (October 2016).  FSF. 2016. C Language Testsuites: \u201cC-torture\u201d. Revision 240758. http:\/\/gcc.gnu.org\/onlinedocs\/gccint\/C-Tests.html . (October 2016)."},{"key":"e_1_2_2_19_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-642-03034-5_14"},{"key":"e_1_2_2_20_1","doi-asserted-by":"publisher","DOI":"10.1145\/2816707.2816714"},{"volume-title":"Flask Web Development: Developing Web Applications with Python. O\u2019Reilly Media","author":"Grinberg Miguel","key":"e_1_2_2_21_1","unstructured":"Miguel Grinberg . 2014. Flask Web Development: Developing Web Applications with Python. O\u2019Reilly Media , Inc . Miguel Grinberg. 2014. Flask Web Development: Developing Web Applications with Python. O\u2019Reilly Media, Inc."},{"key":"e_1_2_2_22_1","volume-title":"Proceedings of the Software Transformation Systems Workshop.","author":"Heering Jan","year":"2004","unstructured":"Jan Heering and Ralf L\u00e4mmel . 2004 . Generic Software Transformations . In Proceedings of the Software Transformation Systems Workshop. Jan Heering and Ralf L\u00e4mmel. 2004. Generic Software Transformations. In Proceedings of the Software Transformation Systems Workshop."},{"key":"e_1_2_2_23_1","unstructured":"Benedikt Huber. 2016. language-c: Analysis and generation of C code. http:\/\/hackage.haskell.org\/package\/language-c . (2016).  Benedikt Huber. 2016. language-c: Analysis and generation of C code. http:\/\/hackage.haskell.org\/package\/language-c . (2016)."},{"key":"e_1_2_2_24_1","unstructured":"JDK Bug System. 2016. javac crash when local from enclosing context is captured multiple times. https:\/\/bugs.openjdk.java. net\/browse\/JDK-8169345 . (2016).  JDK Bug System. 2016. javac crash when local from enclosing context is captured multiple times. https:\/\/bugs.openjdk.java. net\/browse\/JDK-8169345 . (2016)."},{"volume-title":"The Spoofax Language Workbench: Rules for Declarative Specification of Languages and IDEs","author":"Kats Lennart CL","key":"e_1_2_2_25_1","unstructured":"Lennart CL Kats and Eelco Visser . 2010. The Spoofax Language Workbench: Rules for Declarative Specification of Languages and IDEs . Vol. 45 . ACM. Lennart CL Kats and Eelco Visser. 2010. The Spoofax Language Workbench: Rules for Declarative Specification of Languages and IDEs. Vol. 45. ACM."},{"key":"e_1_2_2_26_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-642-32202-0_3"},{"volume-title":"International Summer School on Generative and Transformational Techniques in Software Engineering","author":"Klint Paul","key":"e_1_2_2_27_1","unstructured":"Paul Klint , Tijs van der Storm , and Jurgen Vinju . 2009. EASY Meta-programming with Rascal . In International Summer School on Generative and Transformational Techniques in Software Engineering . Springer , 222\u2013289. Paul Klint, Tijs van der Storm, and Jurgen Vinju. 2009. EASY Meta-programming with Rascal. In International Summer School on Generative and Transformational Techniques in Software Engineering. Springer, 222\u2013289."},{"key":"e_1_2_2_28_1","doi-asserted-by":"publisher","DOI":"10.1145\/3276492"},{"key":"e_1_2_2_29_1","doi-asserted-by":"publisher","DOI":"10.1145\/3135932.3135940"},{"key":"e_1_2_2_30_1","doi-asserted-by":"publisher","DOI":"10.1145\/570186.570188"},{"volume-title":"Scrap Your Boilerplate: A Practical Design Pattern for Generic Programming","author":"L\u00e4mmel Ralf","key":"e_1_2_2_31_1","unstructured":"Ralf L\u00e4mmel and Simon Peyton Jones . 2003. Scrap Your Boilerplate: A Practical Design Pattern for Generic Programming . Vol. 38 . ACM. Ralf L\u00e4mmel and Simon Peyton Jones. 2003. Scrap Your Boilerplate: A Practical Design Pattern for Generic Programming. Vol. 38. ACM."},{"key":"e_1_2_2_32_1","doi-asserted-by":"publisher","DOI":"10.1145\/643603.643621"},{"key":"e_1_2_2_33_1","volume-title":"Typed Combinators for Generic Traversal. In International Symposium on Practical Aspects of Declarative Languages. Springer, 137\u2013154","author":"L\u00e4mmel Ralf","year":"2002","unstructured":"Ralf L\u00e4mmel and Joost Visser . 2002 . Typed Combinators for Generic Traversal. In International Symposium on Practical Aspects of Declarative Languages. Springer, 137\u2013154 . Ralf L\u00e4mmel and Joost Visser. 2002. Typed Combinators for Generic Traversal. In International Symposium on Practical Aspects of Declarative Languages. Springer, 137\u2013154."},{"key":"e_1_2_2_34_1","doi-asserted-by":"publisher","DOI":"10.5555\/645773.668095"},{"key":"e_1_2_2_35_1","volume-title":"2nd IEEE \/ ACM International Symposium on Code Generation and Optimization (CGO 2004)","author":"Lattner Chris","year":"2004","unstructured":"Chris Lattner and Vikram S. Adve . 2004. LLVM: A Compilation Framework for Lifelong Program Analysis &amp; Transformation . In 2nd IEEE \/ ACM International Symposium on Code Generation and Optimization (CGO 2004) , 20-24 March 2004 , San Jose, CA, USA. 75\u201388. Chris Lattner and Vikram S. Adve. 2004. LLVM: A Compilation Framework for Lifelong Program Analysis &amp; Transformation. In 2nd IEEE \/ ACM International Symposium on Code Generation and Optimization (CGO 2004), 20-24 March 2004, San Jose, CA, USA. 75\u201388."},{"key":"e_1_2_2_36_1","doi-asserted-by":"publisher","DOI":"10.1145\/199448.199528"},{"key":"e_1_2_2_37_1","unstructured":"Tim Lindholm Frank Yellin Gilad Bracha and Alex Buckley. 2014. The Java Virtual Machine Specification: Java SE 8 Edition. Pearson Education.   Tim Lindholm Frank Yellin Gilad Bracha and Alex Buckley. 2014. The Java Virtual Machine Specification: Java SE 8 Edition. Pearson Education."},{"key":"e_1_2_2_38_1","unstructured":"Sam Madden. 2017. 6.830 Lab 1: SimpleDB. (2017). http:\/\/db.csail.mit.edu\/6.830\/assignments\/lab1.html  Sam Madden. 2017. 6.830 Lab 1: SimpleDB. (2017). http:\/\/db.csail.mit.edu\/6.830\/assignments\/lab1.html"},{"key":"e_1_2_2_39_1","doi-asserted-by":"publisher","DOI":"10.5555\/832308.837160"},{"key":"e_1_2_2_40_1","volume-title":"Modular Structural Operational Semantics. J. Log. Algebr. Program. 60-61","author":"Mosses Peter D.","year":"2004","unstructured":"Peter D. Mosses . 2004. Modular Structural Operational Semantics. J. Log. Algebr. Program. 60-61 ( 2004 ), 195\u2013228. Peter D. Mosses. 2004. Modular Structural Operational Semantics. J. Log. Algebr. Program. 60-61 (2004), 195\u2013228."},{"key":"e_1_2_2_41_1","doi-asserted-by":"publisher","DOI":"10.1145\/2813885.2737991"},{"key":"e_1_2_2_42_1","unstructured":"Bernard James Pope. 2016. language-python: Parsing and pretty printing of Python code. http:\/\/hackage.haskell.org\/ package\/language-python-0.5.4 . (July 2016).  Bernard James Pope. 2016. language-python: Parsing and pretty printing of Python code. http:\/\/hackage.haskell.org\/ package\/language-python-0.5.4 . (July 2016)."},{"volume-title":"Lua: Test suites. Version 5.3.3. https:\/\/www.lua.org\/tests\/ .","year":"2016","key":"e_1_2_2_43_1","unstructured":"PUC-Rio. 2016 . Lua: Test suites. Version 5.3.3. https:\/\/www.lua.org\/tests\/ . (2016). PUC-Rio. 2016. Lua: Test suites. Version 5.3.3. https:\/\/www.lua.org\/tests\/ . (2016)."},{"key":"e_1_2_2_44_1","unstructured":"Semantic Designs Inc. 2005. Test Coverage tools. http:\/\/www.semanticdesigns.com\/Products\/TestCoverage\/ . (2005).  Semantic Designs Inc. 2005. Test Coverage tools. http:\/\/www.semanticdesigns.com\/Products\/TestCoverage\/ . (2005)."},{"key":"e_1_2_2_45_1","doi-asserted-by":"publisher","DOI":"10.1145\/581690.581691"},{"key":"e_1_2_2_46_1","doi-asserted-by":"publisher","DOI":"10.1017\/S0956796808006758"},{"key":"e_1_2_2_47_1","unstructured":"ECMA TC39. 2014. Test262: ECMAScript Language Conformance Test Suite. Version 5.1. http:\/\/test262.ecmascript.org . (2014).  ECMA TC39. 2014. Test262: ECMAScript Language Conformance Test Suite. Version 5.1. http:\/\/test262.ecmascript.org . (2014)."},{"key":"e_1_2_2_48_1","unstructured":"Danny van Bruggen. 2016. JavaParser: Process Java code programmatically. (2016). http:\/\/javaparser.org  Danny van Bruggen. 2016. JavaParser: Process Java code programmatically. (2016). http:\/\/javaparser.org"},{"key":"e_1_2_2_49_1","unstructured":"Mark van de Brand Jan Heering Paul Klint Ralf L\u00e4mmel and Christian Verhoef. 2003. Language-Parametric Program Restructuring. (2003). http:\/\/www.cs.vu.nl\/lppr\/abstract\/abstract.html  Mark van de Brand Jan Heering Paul Klint Ralf L\u00e4mmel and Christian Verhoef. 2003. Language-Parametric Program Restructuring. (2003). http:\/\/www.cs.vu.nl\/lppr\/abstract\/abstract.html"},{"key":"e_1_2_2_50_1","doi-asserted-by":"publisher","DOI":"10.1109\/WICSA.2001.948406"},{"key":"e_1_2_2_51_1","volume-title":"Language Modularity with the MPS Language Workbench. In 2012 34th International Conference on Software Engineering (ICSE). IEEE, 1449\u20131450","author":"Voelter Markus","year":"2012","unstructured":"Markus Voelter and Vaclav Pech . 2012 . Language Modularity with the MPS Language Workbench. In 2012 34th International Conference on Software Engineering (ICSE). IEEE, 1449\u20131450 . Markus Voelter and Vaclav Pech. 2012. Language Modularity with the MPS Language Workbench. In 2012 34th International Conference on Software Engineering (ICSE). IEEE, 1449\u20131450."},{"key":"e_1_2_2_52_1","doi-asserted-by":"publisher","DOI":"10.1145\/41625.41653"},{"key":"e_1_2_2_53_1","volume-title":"The Expression Problem. Java-genericity mailing list","author":"Wadler Philip","year":"1998","unstructured":"Philip Wadler . 1998. The Expression Problem. Java-genericity mailing list ( 1998 ). Philip Wadler. 1998. The Expression Problem. Java-genericity mailing list (1998)."},{"volume-title":"Testing Statistical Hypotheses of Equivalence and Noninferiority","author":"Wellek Stefan","key":"e_1_2_2_54_1","unstructured":"Stefan Wellek . 2010. Testing Statistical Hypotheses of Equivalence and Noninferiority . CRC Press . Stefan Wellek. 2010. Testing Statistical Hypotheses of Equivalence and Noninferiority. CRC Press."},{"key":"e_1_2_2_55_1","doi-asserted-by":"publisher","DOI":"10.1145\/1596550.1596585"},{"key":"e_1_2_2_56_1","doi-asserted-by":"publisher","DOI":"10.1145\/2814270.2814279"},{"key":"e_1_2_2_57_1","unstructured":"Alan Zimmerman. 2016. language-javascript: Parser for JavaScript. http:\/\/hackage.haskell.org\/package\/ language-javascript-0.6.0.9 . (November 2016).  Alan Zimmerman. 2016. language-javascript: Parser for JavaScript. http:\/\/hackage.haskell.org\/package\/ language-javascript-0.6.0.9 . (November 2016)."}],"container-title":["Proceedings of the ACM on Programming Languages"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3276492","content-type":"unspecified","content-version":"vor","intended-application":"text-mining"},{"URL":"https:\/\/dl.acm.org\/doi\/pdf\/10.1145\/3276492","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2025,6,18]],"date-time":"2025-06-18T01:01:58Z","timestamp":1750208518000},"score":1,"resource":{"primary":{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3276492"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2018,10,24]]},"references-count":56,"journal-issue":{"issue":"OOPSLA","published-print":{"date-parts":[[2018,10,24]]}},"alternative-id":["10.1145\/3276492"],"URL":"https:\/\/doi.org\/10.1145\/3276492","relation":{},"ISSN":["2475-1421"],"issn-type":[{"type":"electronic","value":"2475-1421"}],"subject":[],"published":{"date-parts":[[2018,10,24]]},"assertion":[{"value":"2018-10-24","order":2,"name":"published","label":"Published","group":{"name":"publication_history","label":"Publication History"}}]}}