Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
10.1145/2503887.2503889acmconferencesArticle/Chapter ViewAbstractPublication PagesConference Proceedings
research-article

First-class substitutions in contextual type theory

Published: 23 September 2013 Publication History
  • Get Citation Alerts
  • Abstract

    In this paper, we revisit the theory of first-class substitution in contextual type theory (CTT); in particular, we focus on the abstract notion of substitution variables. This forms the basis for extending Beluga, a dependently typed proof and programming language which already supports first-class contexts and contextual objects, with first-class substitutions. To illustrate the elegance and power of first-class substitution variables, we describe the implementation of a weak normalization proof for the simply-typed lambda-calculus in Beluga.

    Supplementary Material

    ZIP File (lfmtp01.zip)
    contextual-substvars-spine.agda: Partial formalization of results. Includes simply-typed approximations of hereditary substitution, simultaneous substitution and expansion operations. Tested with Agda version 2.3.2

    References

    [1]
    Martin Abadi, Luca Cardelli, Pierre-Louis Curien, and Jean-Jacques Lèvy. Explicit substitutions. In 17th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, pages 31--46. ACM Press, 1990.
    [2]
    Nick Benton, Chung-Kil Hur, AndrewJ. Kennedy, and Conor McBride. Strongly typed term representations in Coq. Journal of Automated Reasoning, 49 (2): 141--159, 2012.
    [3]
    Yves Bertot and Pierre Castéran. Interactive Theorem Proving and Program Development. Coq'Art: The Calculus of Inductive Constructions. Springer, 2004.
    [4]
    Andrew Cave and Brigitte Pientka. Programming with binders and indexed data-types. In 39th Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL'12), pages 413--424. ACM Press, 2012.
    [5]
    Iliano Cervesato and Frank Pfenning. A linear spine calculus. phJournal of Logic and Computation, 13 (5): 639--688, 2003.
    [6]
    Andrew Gacek. The Abella interactive theorem prover (system description). In 4th International Joint Conference on Automated Reasoning, volume 5195 of phLecture Notes in Artificial Intelligence, pages 154--161. Springer, August 2008.
    [7]
    David Gelernter, Suresh Jagannathan, and Thomas London. Environments as first class objects. In Proceedings of the 14th ACM SIGACT-SIGPLAN Symposium on Principles of Programming Languages (POPL'87), pages 98--110, New York, NY, USA, 1987. ACM.
    [8]
    Robert Harper, Furio Honsell, and Gordon Plotkin. A framework for defining logics. Journal of the ACM, 40 (1): 143--184, January 1993.
    [9]
    Masatomo Hashimoto and Atsushi Ohori. A typed context calculus. Theoretical Computer Science, 266 (1-2): 249--272, 2001.
    [10]
    Chantal Keller and Thorsten Altenkirch. Hereditary substitutions for simple types, formalized. In Proceedings of the third ACM SIGPLAN workshop on Mathematically structured functional programming, MSFP '10, pages 3--10, New York, NY, USA, 2010.
    [11]
    Ian A. Mason. Computing with contexts. Higher-Order and Symbolic Computation, 12 (2): 171--201, 1999.
    [12]
    Aleksandar Nanevski, Frank Pfenning, and Brigitte Pientka. Contextual modal type theory. ACM Transactions on Computational Logic, 9 (3): 1--49, 2008.
    [13]
    Shin-Ya Nishizaki. A polymorphic environment calculus and its type-inference algorithm. Higher Order Symbol. Comput., 13 (3): 239--278, 2000.
    [14]
    Ulf Norell. Towards a practical programming language based on dependent type theory. PhD thesis, Department of Computer Science and Engineering, Chalmers University of Technology, September 2007. Technical Report 33D.
    [15]
    Frank Pfenning and Carsten Schürmann. 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 (LNAI 1632), pages 202--206. Springer, 1999.
    [16]
    Brigitte Pientka. A type-theoretic foundation for programming with higher-order abstract syntax and first-class substitutions. In 35th Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL'08), pages 371--382. ACM Press, 2008.
    [17]
    Brigitte Pientka and Joshua Dunfield. Beluga: a framework for programming and reasoning with deductive systems (System Description). In Jürgen Giesl and Reiner Haehnle, editors, 5th International Joint Conference on Automated Reasoning (IJCAR'10), Lecture Notes in Artificial Intelligence (LNAI 6173), pages 15--21. Springer-Verlag, 2010.
    [18]
    Adam B. Poswolsky and Carsten Schürmann. Practical programming with higher-order encodings and dependent types. In 17th European Symposium on Programming (ESOP '08), volume 4960, pages 93--107. Springer, 2008.
    [19]
    Christian Queinnec and David De Roure. Sharing code through first-class environments. In Robert Harper and Richard L. Wexelblat, editors, Proceedings of the 1st ACM SIGPLAN International Conference on Functional Programming (ICFP '96), pages 251--261. ACM, 1996.
    [20]
    Didier Rémy. Type inference for records in a natural extension of ML. Research Report 1431, Institut National de Recherche en Informatique et Automatisme, Rocquencourt, BP 105, 78 153 Le Chesnay Cedex, France, May 1991.
    [21]
    Masahiko Sato, Takafumi Sakurai, and Rod Burstall. Explicit environments. phFundamenta Informaticae, 45 (1-2): 79--115, 2001.
    [22]
    Masahiko Sato, Takafumi Sakurai, and Yukiyoshi Kameyama. A simply typed context calculus with first-class environments. Journal of Functional and Logic Programming, 2002 (4): 1--41, March 2002.
    [23]
    Carsten Schürmann and Jeffrey Sarnat. Structural logical relations. In 23rd Annual Symposium on Logic in Computer Science (LICS), Pittsburgh, PA, USA, pages 69--80. IEEE Computer Society, 2008.

    Cited By

    View all

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image ACM Conferences
    LFMTP '13: Proceedings of the Eighth ACM SIGPLAN international workshop on Logical frameworks & meta-languages: theory & practice
    September 2013
    74 pages
    ISBN:9781450323826
    DOI:10.1145/2503887
    Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

    Sponsors

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    Published: 23 September 2013

    Permissions

    Request permissions for this article.

    Check for updates

    Author Tags

    1. dependent types
    2. higher-order abstract syntax
    3. logical frameworks

    Qualifiers

    • Research-article

    Conference

    ICFP'13
    Sponsor:

    Acceptance Rates

    LFMTP '13 Paper Acceptance Rate 5 of 7 submissions, 71%;
    Overall Acceptance Rate 11 of 20 submissions, 55%

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)9
    • Downloads (Last 6 weeks)0
    Reflects downloads up to 11 Aug 2024

    Other Metrics

    Citations

    Cited By

    View all
    • (2023)Contextual Refinement TypesElectronic Proceedings in Theoretical Computer Science10.4204/EPTCS.396.2396(4-19)Online publication date: 17-Nov-2023
    • (2023)Contextual Modal Type Theory with Polymorphic ContextsProgramming Languages and Systems10.1007/978-3-031-30044-8_11(281-308)Online publication date: 22-Apr-2023
    • (2021)Contextual modal types for algebraic effects and handlersProceedings of the ACM on Programming Languages10.1145/34735805:ICFP(1-29)Online publication date: 19-Aug-2021
    • (2021)Harpoon: Mechanizing Metatheory InteractivelyAutomated Deduction – CADE 2810.1007/978-3-030-79876-5_38(636-648)Online publication date: 5-Jul-2021
    • (2019)A type theory for defining logics and proofsProceedings of the 34th Annual ACM/IEEE Symposium on Logic in Computer Science10.5555/3470152.3470181(1-13)Online publication date: 24-Jun-2019
    • (2019)A Type Theory for Defining Logics and Proofs2019 34th Annual ACM/IEEE Symposium on Logic in Computer Science (LICS)10.1109/LICS.2019.8785683(1-13)Online publication date: Jun-2019
    • (2019)POPLMark reloaded: Mechanizing proofs by logical relationsJournal of Functional Programming10.1017/S095679681900017029Online publication date: 10-Dec-2019
    • (2018)Mechanizing proofs with logical relations – Kripke-styleMathematical Structures in Computer Science10.1017/S096012951800015428:09(1606-1638)Online publication date: 2-Aug-2018
    • (2017)LINCX: A Linear Logical Framework with First-Class ContextsProgramming Languages and Systems10.1007/978-3-662-54434-1_20(530-555)Online publication date: 19-Mar-2017
    • (2015)A Case Study on Logical Relations using Contextual TypesElectronic Proceedings in Theoretical Computer Science10.4204/EPTCS.185.3185(33-45)Online publication date: 27-Jul-2015
    • Show More Cited By

    View Options

    Get Access

    Login options

    View options

    PDF

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader

    Media

    Figures

    Other

    Tables

    Share

    Share

    Share this Publication link

    Share on social media