2014 · 67 citations · 37 references
ComputingComputer ScienceLogicProgramming LanguagesTheory Of ComputationFunctional ProgrammingType CheckingType SystemsAbstract SemanticsAgdaCoqDependent TypesLogical ProofPartial CorrectnessTotal CorrectnessType Safety
Dependently‑typed languages typically enforce termination or allow nontermination at the cost of logical consistency. The paper proposes a core language that merges a termination‑guaranteed logic with a nonterminating, type‑safe programming fragment. It unifies a total‑correctness logic and a call‑by‑value language, sharing syntax and semantics, so that logical expressions can be used as programs, proofs can be passed as arguments, and runtime‑computed proofs can serve as evidence. The resulting language lets programmers handle total and partial functions uniformly, easing the transition from functional to dependently‑typed programming.
Most dependently-typed programming languages either require that all expressions terminate (e.g. Coq, Agda, and Epigram), or allow infinite loops but are inconsistent when viewed as logics (e.g. Haskell, ATS, Ωmega. Here, we combine these two approaches into a single dependently-typed core language. The language is composed of two fragments that share a common syntax and overlapping semantics: a logic that guarantees total correctness, and a call-by-value programming language that guarantees type safety but not termination. The two fragments may interact: logical expressions may be used as programs; the logic may soundly reason about potentially nonterminating programs; programs can require logical proofs as arguments; and "mobile" program values, including proofs computed at runtime, may be used as evidence by the logic. This language allows programmers to work with total and partial functions uniformly, providing a smooth path from functional programming to dependently-typed programming.
37
Thierry Coquand, Gérard Huet · Information and Computation · 1988 · 1.1K citations · Full text
Frank Pfenning, Conal Elliott · ACM SIGPLAN Notices · 1988 · 587 citations · Full text
Dependent types in practical programming
Hongwei Xi, Frank Pfenning · 1999 · 584 citations · Full text
Intensional interpretations of functionals of finite type I
W. W. Tait · Journal of Symbolic Logic · 1967 · 557 citations
Humanities, Mathematics, Logic +13