Skip to main content Accessibility help
  • Print publication year: 2009
  • Online publication date: August 2010

6 - A simple type-theoretic language: Mini-TT



This paper presents a formal description of a small functional language with dependent types. The language contains data types, mutual recursive/inductive definitions and a universe of small types. The syntax, semantics and type system is specified in such a way that the implementation of a parser, interpreter and type checker is straight-forward. The main difficulty is to design the conversion algorithm in such a way that it works for open expressions. The paper ends with a complete implementation in Haskell (around 400 lines of code).


We are going to describe a small language with dependent types, its syntax, operational semantics and type system. This is in the spirit of the paper “A simple applicative language: Mini-ML” by Clément, Despeyroux, and Kahn, where they explain a small functional language. From them we have borrowed the idea of using patterns instead of variables in abstractions and let-bindings. It gives an elegant way to express mutually recursive definitions. We also share with them the view that a programming language should not only be formally specified, but it should also be possible to reason about the correctness of its implementation. There should be a small step from the formal operational semantics to an interpreter and also between the specification of the type system to a type checker.

Recommend this book

Email your librarian or administrator to recommend adding this book to your organisation's collection.

From Semantics to Computer Science
  • Online ISBN: 9780511770524
  • Book DOI:
Please enter your name
Please enter a valid email address
Who would you like to send this to *