Dash, SK;
Allamanis, M;
Barr, ET;
(2018)
RefiNym: using names to refine types.
In: Leavens, GT and Garcia, A and Păsăreanu, CS, (eds.)
Proceedings of the 2018 26th ACM Joint Meeting on European Software Engineering Conference and Symposium on the Foundations of Software Engineering.
(pp. pp. 107-117).
ACM
Preview |
Text
Barr_RefiNym. Using names to refine types_AAM.pdf - Accepted Version Download (324kB) | Preview |
Abstract
Source code is bimodal: it combines a formal, algorithmic channel and a natural language channel of identifiers and comments. In this work, we model the bimodality of code with name flows, an assignment flow graph augmented to track identifier names. Conceptual types are logically distinct types that do not always coincide with program types. Passwords and URLs are example conceptual types that can share the program type string. Our tool, RefiNym, is an unsupervised method that mines a lattice of conceptual types from name flows and reifies them into distinct nominal types. For string, RefiNym finds and splits conceptual types originally merged into a single type, reducing the number of same-type variables per scope from 8.7 to 2.2 while eliminating 21.9% of scopes that have more than one same-type variable in scope. This makes the code more self-documenting and frees the type system to prevent a developer from inadvertently assigning data across conceptual types.
Type: | Proceedings paper |
---|---|
Title: | RefiNym: using names to refine types |
Event: | The 26th ACM Joint Meeting on European Software Engineering Conference and Symposium on the Foundations of Software Engineering |
Location: | New York (NY), USA |
Dates: | 4th-9th November 2018 |
ISBN-13: | 978-1-4503-5573-5 |
Open access status: | An open access version is available from UCL Discovery |
DOI: | 10.1145/3236024.3236042 |
Publisher version: | https://doi.org/10.1145/3236024.3236042 |
Language: | English |
Additional information: | This version is the author accepted manuscript. For information on re-use, please refer to the publisher’s terms and conditions. |
Keywords: | Type Reinement, Information-theoretic Clustering |
UCL classification: | UCL UCL > Provost and Vice Provost Offices > UCL BEAMS UCL > Provost and Vice Provost Offices > UCL BEAMS > Faculty of Engineering Science UCL > Provost and Vice Provost Offices > UCL BEAMS > Faculty of Engineering Science > Dept of Computer Science |
URI: | https://discovery.ucl.ac.uk/id/eprint/10066384 |
Archive Staff Only
View Item |