DeepAI AI Chat
Log In Sign Up

Practical Sized Typing for Coq

by   Jonathan Chan, et al.

Termination of recursive functions and productivity of corecursive functions are important for maintaining logical consistency in proof assistants. However, contemporary proof assistants, such as Coq, rely on syntactic criteria that prevent users from easily writing obviously terminating or productive programs, such as quicksort. This is troublesome, since there exist theories for type-based termination- and productivity-checking. In this paper, we present a design and implementation of sized type checking and inference for Coq. We extend past work on sized types for the Calculus of (Co)Inductive Constructions (CIC) with support for global definitions found in Gallina, and extend the sized-type inference algorithm to support completely unannotated Gallina terms. This allows our design to maintain complete backward compatibility with existing Coq developments. We provide an implementation that extends the Coq kernel with optional support for sized types.


page 1

page 2

page 3

page 4


Circular Proofs as Processes: Type-Based Termination via Arithmetic Refinements

Type systems for concurrent programs guarantee such desirable properties...

Consistency of the Predicative Calculus of Cumulative Inductive Constructions (pCuIC)

In order to avoid well-know paradoxes associated with self-referential d...

System FR as Foundations for Stainless

We present the design, implementation, and foundation of a verifier for ...

Complete Bidirectional Typing for the Calculus of Inductive Constructions

This article presents a bidirectional type system for the Calculus of In...

Diamonds are not forever: Liveness in reactive programming with guarded recursion

When designing languages for functional reactive programming (FRP) the m...

Design and Implementation of the Andromeda Proof Assistant

Andromeda is an LCF-style proof assistant where the user builds derivabl...