How to Evaluate Blame for Gradual Types, Part 2
Open Access
- 30 August 2023
- journal article
- research article
- Published by Association for Computing Machinery (ACM) in Proceedings of the ACM on Programming Languages
- Vol. 7 (ICFP) , 159-186
Abstract
Equipping an existing programming language with a gradual type system requires two major steps. The first and most visible one in academia is to add a notation for types and a type checking apparatus. The second, highly practical one is to provide a type veneer for the large number of existing untyped libraries; doing so enables typed components to import pieces of functionality and get their uses type-checked, without any changes to the libraries. When programmers create such typed veneers for libraries, they make mistakes that persist and cause trouble. The question is whether the academically investigated run-time checks for gradual type systems assist programmers with debugging such mistakes. This paper provides a first, surprising answer to this question via a rational-programmer investigation: run-time checks alone are typically less helpful than the safety checks of the underlying language. Combining Natural run-time checks with blame, however, provides significantly superior debugging hints.Keywords
Funding Information
- NSF (SHF 1763922,2030859,2237984)
This publication has 51 references indexed in Scilit:
- Counter-factual typing for debugging type errors2014
- An empirical study on the impact of static typing on software maintainabilityEmpirical Software Engineering, 2013
- Experience report2013
- Chaperones and impersonators2012
- The ins and outs of gradual type inference2012
- Well-Typed Programs Can’t Be Blamed2009
- Featherweight JavaACM Transactions on Programming Languages and Systems, 2001
- In Search of Homo Economicus: Behavioral Experiments in 15 Small-Scale SocietiesAmerican Economic Review, 2001
- Binary component adaptation1998
- Fatal error in pass zero: How not to confuse novices1984