{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,3,6]],"date-time":"2026-03-06T21:02:40Z","timestamp":1772830960052,"version":"3.50.1"},"reference-count":44,"publisher":"Association for Computing Machinery (ACM)","issue":"OOPSLA1","license":[{"start":{"date-parts":[[2022,4,29]],"date-time":"2022-04-29T00:00:00Z","timestamp":1651190400000},"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":[[2022,4,29]]},"abstract":"<jats:p>Code completion is an editor service in IDEs that proposes code fragments for the user to insert at the caret position in their code. Code completion should be sound and complete. It should be sound, such that it only proposes fragments that do not violate the syntactic and static semantic rules of the language. It should be complete, such that it proposes all valid fragments so that code completion can be used to construct all programs. To realize soundness and completeness, code completion should be informed by the language definition. In practice, the implementation of code completion is an additional effort in the implementation of a language.<\/jats:p>\n          <jats:p>In this paper, we develop a framework for language-parametric semantic code completion for statically typed programming languages based on their specification of syntax and static semantics, realizing the implementation of a code completion editor service with minimal additional effort. The framework builds on the SDF3 syntax definition formalism and the Statix static semantics specification language. The algorithm reinterprets the static semantics definition to find sound expansions of predicates and solutions to name resolution queries in scope graphs. This allows a search strategy to explore the solution space and synthesize completion proposals. The implementation of the strategy language and code completion algorithm extend the implementation of the Statix solver, and can be used for any language defined in Statix. We demonstrate soundness and completeness of the completion proposal synthesis, and evaluate its performance.<\/jats:p>","DOI":"10.1145\/3527329","type":"journal-article","created":{"date-parts":[[2022,4,29]],"date-time":"2022-04-29T15:42:03Z","timestamp":1651246923000},"page":"1-30","update-policy":"https:\/\/doi.org\/10.1145\/crossmark-policy","source":"Crossref","is-referenced-by-count":9,"title":["Language-parametric static semantic code completion"],"prefix":"10.1145","volume":"6","author":[{"ORCID":"https:\/\/orcid.org\/0000-0003-0196-0567","authenticated-orcid":false,"given":"Daniel A. A.","family":"Pelsmaeker","sequence":"first","affiliation":[{"name":"Delft University of Technology, Netherlands"}],"role":[{"role":"author","vocabulary":"crossref"}]},{"ORCID":"https:\/\/orcid.org\/0000-0001-5117-0921","authenticated-orcid":false,"given":"Hendrik","family":"van Antwerpen","sequence":"additional","affiliation":[{"name":"Delft University of Technology, Netherlands"}],"role":[{"role":"author","vocabulary":"crossref"}]},{"ORCID":"https:\/\/orcid.org\/0000-0003-0622-7639","authenticated-orcid":false,"given":"Casper Bach","family":"Poulsen","sequence":"additional","affiliation":[{"name":"Delft University of Technology, Netherlands"}],"role":[{"role":"author","vocabulary":"crossref"}]},{"ORCID":"https:\/\/orcid.org\/0000-0002-7384-3370","authenticated-orcid":false,"given":"Eelco","family":"Visser","sequence":"additional","affiliation":[{"name":"Delft University of Technology, Netherlands"}],"role":[{"role":"author","vocabulary":"crossref"}]}],"member":"320","published-online":{"date-parts":[[2022,4,29]]},"reference":[{"key":"e_1_2_2_1_1","volume-title":"Modern Compiler Implementation in Java","author":"Appel Andrew W.","year":"2060","unstructured":"Andrew W. Appel . 2002. Modern Compiler Implementation in Java , 2 nd edition. Cambridge University Press . isbn:0-521-8 2060 -X Andrew W. Appel. 2002. Modern Compiler Implementation in Java, 2nd edition. Cambridge University Press. isbn:0-521-82060-X","edition":"2"},{"key":"e_1_2_2_2_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSME.2014.110"},{"key":"e_1_2_2_3_1","doi-asserted-by":"publisher","DOI":"10.1002\/smr.1791"},{"key":"e_1_2_2_4_1","doi-asserted-by":"publisher","DOI":"10.1017\/S095679681300018X"},{"key":"e_1_2_2_5_1","doi-asserted-by":"publisher","DOI":"10.1145\/1595696.1595728"},{"key":"e_1_2_2_6_1","doi-asserted-by":"publisher","DOI":"10.1145\/2997364.2997374"},{"key":"e_1_2_2_7_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-030-58768-0_1"},{"key":"e_1_2_2_8_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-662-44202-9_20"},{"key":"e_1_2_2_9_1","volume-title":"Language Workbenches: The Killer-App for Domain Specific Languages? http:\/\/www.martinfowler.com\/articles\/languageWorkbench.html","author":"Fowler Martin","year":"2005","unstructured":"Martin Fowler . 2005 . Language Workbenches: The Killer-App for Domain Specific Languages? http:\/\/www.martinfowler.com\/articles\/languageWorkbench.html Martin Fowler. 2005. Language Workbenches: The Killer-App for Domain Specific Languages? http:\/\/www.martinfowler.com\/articles\/languageWorkbench.html"},{"key":"e_1_2_2_10_1","doi-asserted-by":"publisher","DOI":"10.1561\/2500000010"},{"key":"e_1_2_2_11_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE.2019.00101"},{"key":"e_1_2_2_12_1","unstructured":"Jetbrains. 2021. Jetbrains MPS. http:\/\/jetbrains.com\/mps\/  Jetbrains. 2021. Jetbrains MPS. http:\/\/jetbrains.com\/mps\/"},{"key":"e_1_2_2_13_1","doi-asserted-by":"publisher","DOI":"10.1145\/1869459.1869497"},{"key":"e_1_2_2_14_1","doi-asserted-by":"publisher","DOI":"10.1109\/SCAM.2009.28"},{"key":"e_1_2_2_15_1","volume-title":"Vinju","author":"Klint Paul","year":"2010","unstructured":"Paul Klint , Tijs van der Storm , and Jurgen J . Vinju . 2010 . EASY Meta-Programming with Rascal. Leveraging the Extract-Analyze-SYnthesize Paradigm for Meta-Programming. In Proceedings of the 3rd International Summer School on Generative and Transformational Techniques in Software Engineering (GTTSE\u201909) (LNCS). Springer . to appear Paul Klint, Tijs van der Storm, and Jurgen J. Vinju. 2010. EASY Meta-Programming with Rascal. Leveraging the Extract-Analyze-SYnthesize Paradigm for Meta-Programming. In Proceedings of the 3rd International Summer School on Generative and Transformational Techniques in Software Engineering (GTTSE\u201909) (LNCS). Springer. to appear"},{"key":"e_1_2_2_16_1","doi-asserted-by":"publisher","DOI":"10.1109\/SCAM.2019.00023"},{"key":"e_1_2_2_17_1","doi-asserted-by":"publisher","DOI":"10.1007\/11617990_10"},{"key":"e_1_2_2_18_1","doi-asserted-by":"publisher","DOI":"10.1145\/3408991"},{"key":"e_1_2_2_19_1","doi-asserted-by":"publisher","DOI":"10.4230\/LIPIcs.ECOOP.2019.21"},{"key":"e_1_2_2_20_1","volume-title":"Dependently typed functional programs and their proofs. Ph. D. Dissertation","author":"McBride Conor","unstructured":"Conor McBride . 2000. Dependently typed functional programs and their proofs. Ph. D. Dissertation . University of Edinburgh, UK. http:\/\/ethos.bl.uk\/OrderDetails.do?uin=uk.bl.ethos.561753 British Library , EThOS Conor McBride. 2000. Dependently typed functional programs and their proofs. Ph. D. Dissertation. University of Edinburgh, UK. http:\/\/ethos.bl.uk\/OrderDetails.do?uin=uk.bl.ethos.561753 British Library, EThOS"},{"key":"e_1_2_2_21_1","doi-asserted-by":"publisher","DOI":"10.1007\/11546382_3"},{"key":"e_1_2_2_22_1","doi-asserted-by":"publisher","DOI":"10.1017\/S0956796803004829"},{"key":"e_1_2_2_23_1","volume-title":"Towards a practical programming language based on dependent type theory. Ph. D. Dissertation. Department of Computer Science and Engineering","author":"Norell Ulf","unstructured":"Ulf Norell . 2007. Towards a practical programming language based on dependent type theory. Ph. D. Dissertation. Department of Computer Science and Engineering , Chalmers University of Technology . SE-412 96 G\u00f6teborg, Sweden. Ulf Norell. 2007. Towards a practical programming language based on dependent type theory. Ph. D. Dissertation. Department of Computer Science and Engineering, Chalmers University of Technology. SE-412 96 G\u00f6teborg, Sweden."},{"key":"e_1_2_2_24_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-662-46669-8_9"},{"key":"e_1_2_2_25_1","first-page":"3","volume-title":"Proceedings of the ACM on Programming Languages","author":"Omar Cyrus","year":"2019","unstructured":"Cyrus Omar , Ian Voysey , Ravi Chugh , and Matthew A. Hammer . 2019. Live functional programming with typed holes . Proceedings of the ACM on Programming Languages , 3 ( 2019 ), https:\/\/dl.acm.org\/citation.cfm?id=3290327 Cyrus Omar, Ian Voysey, Ravi Chugh, and Matthew A. Hammer. 2019. Live functional programming with typed holes. Proceedings of the ACM on Programming Languages, 3 (2019), https:\/\/dl.acm.org\/citation.cfm?id=3290327"},{"key":"e_1_2_2_26_1","volume-title":"Proceedings of the 44th ACM SIGPLAN Symposium on Principles of Programming Languages, POPL 2017","author":"Omar Cyrus","year":"2017","unstructured":"Cyrus Omar , Ian Voysey , Michael Hilton , Jonathan Aldrich , and Matthew A. Hammer . 2017. Hazelnut: a bidirectionally typed structure editor calculus . In Proceedings of the 44th ACM SIGPLAN Symposium on Principles of Programming Languages, POPL 2017 , Paris, France , January 18-20, 2017 , Giuseppe Castagna and Andrew D. Gordon (Eds.). ACM, 86\u201399. isbn:978-1-4503-4660-3 http:\/\/dl.acm.org\/citation.cfm?id=3009900 Cyrus Omar, Ian Voysey, Michael Hilton, Jonathan Aldrich, and Matthew A. Hammer. 2017. Hazelnut: a bidirectionally typed structure editor calculus. In Proceedings of the 44th ACM SIGPLAN Symposium on Principles of Programming Languages, POPL 2017, Paris, France, January 18-20, 2017, Giuseppe Castagna and Andrew D. Gordon (Eds.). ACM, 86\u201399. isbn:978-1-4503-4660-3 http:\/\/dl.acm.org\/citation.cfm?id=3009900"},{"key":"e_1_2_2_27_1","doi-asserted-by":"publisher","DOI":"10.1145\/3357766.3359534"},{"key":"e_1_2_2_28_1","doi-asserted-by":"publisher","DOI":"10.1145\/3358711.3361627"},{"key":"e_1_2_2_29_1","doi-asserted-by":"publisher","DOI":"10.5281\/zenodo.6367565"},{"key":"e_1_2_2_30_1","doi-asserted-by":"publisher","DOI":"10.4230\/LIPIcs.ECOOP.2019.26"},{"key":"e_1_2_2_31_1","doi-asserted-by":"publisher","DOI":"10.1145\/2254064.2254098"},{"key":"e_1_2_2_32_1","unstructured":"Rascal. 2021. TypePal: Name and Type Analysis Made Easy. http:\/\/docs.rascal-mpl.org\/unstable\/TypePal  Rascal. 2021. TypePal: Name and Type Analysis Made Easy. http:\/\/docs.rascal-mpl.org\/unstable\/TypePal"},{"key":"e_1_2_2_33_1","doi-asserted-by":"publisher","DOI":"10.1145\/2594291.2594321"},{"key":"e_1_2_2_34_1","doi-asserted-by":"publisher","DOI":"10.1145\/3428248"},{"key":"e_1_2_2_35_1","doi-asserted-by":"publisher","DOI":"10.1145\/3441296.3441395"},{"key":"e_1_2_2_36_1","doi-asserted-by":"publisher","DOI":"10.1145\/1449764.1449787"},{"key":"e_1_2_2_37_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-642-10672-9_3"},{"key":"e_1_2_2_38_1","doi-asserted-by":"publisher","DOI":"10.1145\/3136014.3136034"},{"key":"e_1_2_2_39_1","unstructured":"Michael Steindorfer. 2017. Efficient Immutable Collections. Ph. D. Dissertation. Universiteit van Amsterdam.  Michael Steindorfer. 2017. Efficient Immutable Collections. Ph. D. Dissertation. Universiteit van Amsterdam."},{"key":"e_1_2_2_40_1","doi-asserted-by":"publisher","DOI":"10.1145\/1988783.1988794"},{"key":"e_1_2_2_41_1","doi-asserted-by":"publisher","DOI":"10.1145\/2847538.2847543"},{"key":"e_1_2_2_42_1","doi-asserted-by":"publisher","DOI":"10.1145\/3276484"},{"key":"e_1_2_2_43_1","doi-asserted-by":"publisher","DOI":"10.1145\/289423.289425"},{"key":"e_1_2_2_44_1","unstructured":"Xtext Team. 2021. Xtext. https:\/\/www.eclipse.org\/Xtext\/  Xtext Team. 2021. Xtext. https:\/\/www.eclipse.org\/Xtext\/"}],"container-title":["Proceedings of the ACM on Programming Languages"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3527329","content-type":"unspecified","content-version":"vor","intended-application":"text-mining"},{"URL":"https:\/\/dl.acm.org\/doi\/pdf\/10.1145\/3527329","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2025,6,17]],"date-time":"2025-06-17T20:18:53Z","timestamp":1750191533000},"score":1,"resource":{"primary":{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3527329"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2022,4,29]]},"references-count":44,"journal-issue":{"issue":"OOPSLA1","published-print":{"date-parts":[[2022,4,29]]}},"alternative-id":["10.1145\/3527329"],"URL":"https:\/\/doi.org\/10.1145\/3527329","relation":{},"ISSN":["2475-1421"],"issn-type":[{"value":"2475-1421","type":"electronic"}],"subject":[],"published":{"date-parts":[[2022,4,29]]},"assertion":[{"value":"2022-04-29","order":2,"name":"published","label":"Published","group":{"name":"publication_history","label":"Publication History"}}]}}