Explicit Substitutions for Contextual Type Theory
2010, Electronic Proceedings in Theoretical Computer Science
https://doi.org/10.4204/EPTCS.34.3Abstract
In this paper, we present an explicit substitution calculus which distinguishes between ordinary bound variables and meta-variables. Its typing discipline is derived from contextual modal type theory. We first present a dependently typed lambda calculus with explicit substitutions for ordinary variables and explicit meta-substitutions for meta-variables. We then present a weak head normalization procedure which performs both substitutions lazily and in a single pass thereby combining substitution walks for the two different classes of variables. Finally, we describe a bidirectional type checking algorithm which uses weak head normalization and prove soundness.
References (18)
- Martín Abadi, Luca Cardelli, Pierre-Louis Curien & Jean-Jacques Lévy (1991): Explicit Substitutions. Jour- nal of Functional Programming 1(4), pp. 375-416.
- Andreas Abel & Thierry Coquand (2007): Untyped Algorithmic Equality for Martin-Löf's Logical Frame- work with Surjective Pairs. Fundamenta Informaticae 77(4), pp. 345-395. TLCA'05 special issue.
- Robin Adams (2005): A Modular Hierarchy of Logical Frameworks. Ph.D. thesis, University of Manchester.
- Ana Bove, Peter Dybjer & Ulf Norell (2009): A Brief Overview of Agda -A Functional Language with Dependent Types. In: Stefan Berghofer, Tobias Nipkow, Christian Urban & Makarius Wenzel, editors: 22nd International Conference on Theorem Proving in Higher Order Logics (TPHOLs'09), Lecture Notes in Computer Science 5674, Springer-Verlag, pp. 73-78. Available at http://dx.doi.org/10.1007/ 978-3-642-03359-9_6.
- Thierry Coquand (1991): An Algorithm for Testing Conversion in Type Theory. In: G. Huet & G. Plotkin, editors: Logical Frameworks, Cambridge University Press, pp. 255-279.
- Thierry Coquand (1996): An Algorithm for Type-Checking Dependent Types. In: Mathematics of Program Construction. Selected Papers from the Third International Conference on the Mathematics of Program Con- struction (July 17-21, 1995, Kloster Irsee, Germany), Science of Computer Programming 26, Elsevier, pp. 167-177.
- Gilles Dowek, Thérèse Hardin & Claude Kirchner (2000): Higher Order Unification via Explicit Substitu- tions. Information and Computation 157(1-2), pp. 183-235.
- Robert Harper & Frank Pfenning (2005): On Equivalence and Canonical Forms in the LF Type Theory. ACM Transactions on Computational Logic 6(1), pp. 61-101.
- Chuck Liang, Gopalan Nadathur & Xiaochu Qi (2005): Choices in representation and reduction strategies for lambda terms in intensional contexts. Journal of Automated Reasoning 33(2), pp. 89-132.
- Gopalan Nadathur & Debra Sue Wilson (1998): A Notation for Lambda Terms: A Generalization of Environ- ments. Theoretical Computer Science 198(1-2), pp. 49-98. Available at http://dx.doi.org/10.1016/ S0304-3975(97)00184-9.
- Aleksandar Nanevski, Frank Pfenning & Brigitte Pientka (2008): Contextual modal type theory. ACM Transactions on Computational Logic 9(3), pp. 1-49.
- Ulf Norell (2007): Towards a practical programming language based on dependent type theory. Ph.D. thesis, Department of Computer Science and Engineering, Chalmers University of Technology, Göteborg, Sweden.
- Frank Pfenning & Carsten Schürmann (1999): System Description: Twelf -A Meta-Logical Framework for Deductive Systems. In: H. Ganzinger, editor: 16th International Conference on Automated Deduction (CADE-16), Lecture Notes in Artificial Intelligence 1632, Springer, pp. 202-206.
- Brigitte Pientka (2003): Tabled higher-order logic programming. Ph.D. thesis, Department of Computer Science, Carnegie Mellon University. CMU-CS-03-185.
- Brigitte Pientka & Joshua Dunfield (2008): Programming with proofs and explicit contexts. In: ACM SIG- PLAN Symposium on Principles and Practice of Declarative Programming (PPDP'08), ACM Press, pp. 163-173.
- Brigitte Pientka & Joshua Dunfield (2010): Beluga: A Framework for Programming and Reasoning with Deductive Systems (System Description). In: Jürgen Giesl & Reiner Hähnle, editors: 5th International Joint Conference on Automated Reasoning (IJCAR'10), Lecture Notes in Computer Science, Springer-Verlag.
- Adam Poswolsky & Carsten Schürmann (2009): System Description: Delphin -A Functional Programming Language for Deductive Systems. Electronic Notes in Theoretical Computer Science 228, pp. 113-120. Available at http://dx.doi.org/10.1016/j.entcs.2008.12.120.
- Adam Poswolsky & Carsten Schürmann (2008): Practical programming with higher-order encodings and dependent types. In: 17th European Symposium on Programming (ESOP '08), Lecture Notes in Computer Science 4960, Springer, p. 93.