Contextual Modal Type Theory with Polymorphic Contexts
Yuito Murase, Yuichi Nishiwaki, Atsushi Igarashi

TL;DR
This paper introduces mbda_{orall[]}, an advanced modal type theory with polymorphic contexts, enabling more flexible code manipulation and demonstrating its expressive power through formal properties and embeddings.
Contribution
It extends contextual modal type theory with polymorphism over contexts, allowing multiple parts of a context to be abstracted, and formalizes its properties and expressive capabilities.
Findings
mbda_{orall[]} is formally defined with type system and operational semantics.
The system is proven to have subject reduction, strong normalization, and confluence.
A type-preserving embedding from a fragment of temporal logic-based calculus into mbda_{orall[]} is demonstrated.
Abstract
Modal types -- types that are derived from proof systems of modal logic -- have been studied as theoretical foundations of metaprogramming, where program code is manipulated as first-class values. In modal type systems, modality corresponds to a type constructor for code types and controls free variables and their types in code values. Nanevski et al. have proposed contextual modal type theory, which has modal types with fine-grained information on free variables: modal types are explicitly indexed by contexts -- the types of all free variables in code values. This paper presents , a novel extension of contextual modal type theory with parametric polymorphism over contexts. Such an extension has been studied in the literature but unlike earlier proposals, is more general in that multiple parts of a single context can be abstracted. We…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsLogic, programming, and type systems · Formal Methods in Verification · Software Engineering Research
