Type soundness proofs with definitional interpreters

被引:0
|
作者
Amin N. [1 ]
Rompf T. [2 ]
机构
[1] Amin, Nada
[2] Rompf, Tiark
来源
| 2017年 / Association for Computing Machinery卷 / 52期
基金
美国国家科学基金会;
关键词
Definitional interpreters; dependent object types; DOT; Scala; type soundness;
D O I
10.1145/3009837.3009866
中图分类号
学科分类号
摘要
While type soundness proofs are taught in every graduate PL class, the gap between realistic languages and what is accessible to formal proofs is large. In the case of Scala, it has been shown that its formal model, the Dependent Object Types (DOT) calculus, cannot simultaneously support key metatheoretic properties such as environment narrowing and subtyping transitivity, which are usually required for a type soundness proof. Moreover, Scala and many other realistic languages lack a general substitution property. The first contribution of this paper is to demonstrate how type soundness proofs for advanced, polymorphic, type systems can be carried out with an operational semantics based on high-level, definitional interpreters, implemented in Coq. We present the first mechanized soundness proofs in this style for System F and several extensions, including mutable references. Our proofs use only straightforward induction, which is significant, as the combination of big-step semantics, mutable references, and polymorphism is commonly believed to require coinductive proof techniques. The second main contribution of this paper is to show how DOT-like calculi emerge from straightforward generalizations of the operational aspects of F, exposing a rich design space of calculi with path-dependent types inbetween System F and DOT, which we dub the System D Square. By working directly on the target language, definitional interpreters can focus the design space and expose the invariants that actually matter at runtime. Looking at such runtime invariants is an exciting new avenue for type system design. © 2017 ACM.
引用
收藏
页码:666 / 679
页数:13
相关论文
共 50 条
  • [41] Proving ML type soundness within Coq
    Dubois, C
    THEOREM PROVING IN HIGHER ORDER LOGICS, PROCEEDINGS, 2000, 1869 : 126 - 144
  • [42] Coinductive Soundness of Corecursive Type Class Resolution
    Farka, Frantisek
    Komendantskaya, Ekaterina
    Hammond, Kevin
    LOGIC-BASED PROGRAM SYNTHESIS AND TRANSFORMATION, LOPSTR 2016, 2017, 10184 : 311 - 327
  • [43] Type Soundness for Dependent Object Types (DOT)
    Rompf, Tiark
    Amin, Nada
    ACM SIGPLAN NOTICES, 2016, 51 (10) : 624 - 641
  • [44] Refunctionalization of Abstract Abstract Machines Bridging the Gap between Abstract Abstract Machines and Abstract Definitional Interpreters (Functional Pearl)
    Wei, Guannan
    Decker, James
    Rompf, Tiark
    PROCEEDINGS OF THE ACM ON PROGRAMMING LANGUAGES, 2018,
  • [45] Method Inlining, Dynamic Class Loading, and Type Soundness
    Glew, Neal
    Palsberg, Jens
    JOURNAL OF OBJECT TECHNOLOGY, 2005, 4 (08): : 33 - 53
  • [46] TYPE AND INCIDENCE OF SURGICAL DISEASES FOUND IN SOUNDNESS EXAMINATIONS
    TELLHELM, B
    PRAKTISCHE TIERARZT, 1977, 58 (03): : 172 - &
  • [47] Efficient Software Model Checking of Soundness of Type Systems
    Roberson, Michael
    Harries, Melanie
    Darga, Paul T.
    Boyapati, Chandrasekhar
    ACM SIGPLAN NOTICES, 2008, 43 (10) : 493 - 504
  • [48] A TYPE SOUNDNESS PROOF FOR VARIABLES IN LCF-ML
    VOLPANO, D
    SMITH, G
    INFORMATION PROCESSING LETTERS, 1995, 56 (03) : 141 - 146
  • [49] Combinatorial proofs of a type of binomial identity
    Feng, H
    Zhang, ZH
    ARS COMBINATORIA, 2005, 74 : 245 - 260
  • [50] Simple proofs of Olevskii type theorems
    Veits, BE
    MATHEMATICAL NOTES, 1996, 59 (3-4) : 241 - 246