What is decidable about gradual types?
Abstract
Programmers can use gradual types to migrate programs to have more precise type annotations and thereby improve their readability, efficiency, and safety. Such migration requires an exploration of the migration space and can benefit from tool support, as shown in previous work. Our goal is to provide a foundation for better tool support by settling decidability questions about migration with gradual types. We present three algorithms and a hardness result for deciding key properties and we explain how they can be useful during an exploration. In particular, we show how to decide whether the migration space is finite, whether it has a top element, and whether it is a singleton. We also show that deciding whether it has a maximal element is NP-hard. Our implementation of our algorithms worked as expected on a suite of microbenchmarks.
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
6 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- Practical Inference of Nullability Types cites Solver-based gradual type migration
- C to checked C by 3c cites Solver-based gradual type migration
- QuAC: Quick Attribute-Centric Type Inference for Python cites Solver-based gradual type migration
- Inference of Resource Management Specifications cites Solver-based gradual type migration
Cited by top-tier papers6
- C to checked C by 3cAravind Machiry, John H. Kastner, Matt McCutchen, Aaron Eline et al.OOPSLA 2022 · 20 citations
- Solver-based gradual type migrationLuna Phipps-Costin, Carolyn Jane Anderson, Michael Greenberg, Arjun GuhaOOPSLA 2021 · 16 citations
- Practical Inference of Nullability TypesNima Karimipour, Justin Pham, Lazaro Clapp, Manu SridharanFSE 2023 · 6 citations
- QuAC: Quick Attribute-Centric Type Inference for PythonJifeng Wu, Caroline LemieuxOOPSLA 2024 · 2 citations
- Inference of Resource Management SpecificationsNarges Shadab, Pritam M. Gharat, Shrey Tiwari, Michael D. Ernst et al.OOPSLA 2023 · 2 citations
Related papers
- How Profilers Can Help Navigate Type MigrationBen Greenman, Matthias Felleisen, Christos DimoulasOOPSLA 2023 · 1 citation
- Gradually Typed Languages Should Be Vigilant!Olek Gierczak, Lucy Menon, Christos Dimoulas, Amal AhmedOOPSLA 2024 · 1 citation
- Top-Down or Bottom-Up? Complexity Analyses of Synchronous Multiparty Session TypesThien Udomsrirungruang, Nobuko YoshidaPOPL 2025 · 7 citations
- Denotational Semantics of Gradual Typing using Synthetic Guarded Domain TheoryEric Giovannini, Tingting Ding, Max S. NewPOPL 2025 · 2 citations
- Transitioning from structural to nominal code with efficient gradual typingFabian Muehlboeck, Ross TateOOPSLA 2021 · 8 citations
