Skip to main content Accessibility help

Idris, a general-purpose dependently typed programming language: Design and implementation

  • EDWIN BRADY (a1)


Many components of a dependently typed programming language are by now well understood, for example, the underlying type theory, type checking, unification and evaluation. How to combine these components into a realistic and usable high-level language is, however, folklore, discovered anew by successive language implementors. In this paper, I describe the implementation of Idris, a new dependently typed functional programming language. Idris is intended to be a general-purpose programming language and as such provides high-level concepts such as implicit syntax, type classes and do notation. I describe the high-level language and the underlying type theory, and present a tactic-based method for elaborating concrete high-level syntax with implicit arguments and type classes into a fully explicit type theory. Furthermore, I show how this method facilitates the implementation of new high-level language constructs.



Hide All
Altenkirch, T., Danielsson, N. A., Löh, A. & Oury, N. (2010) Dependent types without the sugar. In Tenth International Symposium on Functional and Logic Programming (FLOPS 2010), Blume, M., Kobayashi, N. & Vidal, G. (eds), Lecture Notes in Computer Science 6009. Berlin, Germany: Springer, pp. 4055.
Asperti, A., Ricciotti, W., Coen, C. S. & Tassi, E. (2011) The Matita Interactive theorem prover. In Automated Deduction – CADE-23, Lecture Notes in Computer Science, 6803. Berlin, Germany: Springer, pp. 6469.
Asperti, A., Ricciotti, W., Coen, C. S. & Tassi, E. (2012) A bi-directional refinement algorithm for the calculus of (co)inductive constructions. Logical Methods Comput. Sci. 8, 149.
Augustsson, L. (1985) Compiling pattern matching. In Functional Programming Languages and Computer Architecture, Jouannaud, J.-P. (ed), Lecture Notes in Computer Science, vol. 201. Berlin, Germany: Springer, pp. 368381.
Bertot, Y. & Castéran, P. (2004) Interactive Theorem Proving and Program Development: Coq'Art: the Calculus of Inductive Constructions. Berlin, Germany: Springer.
Brady, E. (2005) Practical Implementation of a Dependently Typed Functional Programming Language, PhD thesis, University of Durham, Durham, NC.
Brady, E. (2006, September) Ivor, a proof engine. In Implementation and Application of Functional Languages (IFL'06), Budapest, Hungary, pp. 145162.
Brady, E. (2011a) Epic – A library for generating compilers. In Proceedings of the International Symposium on Trends in Functional Programming (TFP11), Madrid, Spain.
Brady, E. (2011b) Idris – Systems programming meets full dependent types. In Proceedings of the 5th ACM Workshop on Programming Languages Meets Program Verification (PLPV '11). New York, NY: ACM Press.
Brady, E. (2013). Programming in Idris : A Tutorial. Available at
Brady, E., McBride, C. & McKinna, J. (2003) Inductive families need not store their indices. In Types for Proofs and Programs (TYPES 2003), Torino, Italy. Berlin, Germany: Springer.
Chapman, J., Altenkirch, T. & McBride, C. (2005). Epigram reloaded: A standalone typechecker for ETT. In Sixth Symposium on Trends in Functional Programming, Tallinn, Estonia.
Chapman, J., Dagand, P.-E., McBride, C. & Morris, P. (2010, September) The gentle art of levitation. In Proceedings of 15th ACM SIGPLAN International Conference on Functional Programming (ICFP '10), Baltimore, MD, vol. 45.
Coquand, T. (1986) An analysis of Girard's paradox. In Proceedings of the First IEEE Symposium on Logic in Computer Science ( LICS'86). Washington, DC: IEEE Comp. Soc. Press, pp. 227246.
Delahaye, D. (2000) A tactic language for the system Coq. In Logic for Programming and Automated Reasoning (LPAR). New York, NY: Springer, pp. 8595.
Dybjer, P. (1994) Inductive families. Form. Asp. Comput. 6 (4), 440465.
Hancock, P. & Setzer, A. (2000, August) Interactive programs in dependent type theory. In Proceedings of the 14th Annual Conference of the EACSL on Computer Science Logic, Oxford, UK, pp. 317331.
Huet, G. (1997) The zipper. J. Funct. Program. 7 (5), 549554.
Kimmell, G., Stump, A., Eades, H. D. III, Fu, P., Sheard, T., Weirich, S., Casinghino, C., Sjöberg, V., Collins, N. & Ahn, K. Y. (2012) Equational reasoning about programs with general recursion and call-by-value semantics. In Proceedings of the 6th ACM workshop on Programming Languages Meets Program Verification (PLPV '12), Philadelphia, PA.
Lee, C. S., Jones, N. D. & Ben-Amram, A. M. (2001) The size-change principle for program termination. ACM SIGPLAN Not. 36 (3), 8192.
Löh, A., McBride, C. & Swierstra, W. (2010) A tutorial implementation of a dependently typed lambda calculus. Fundamenta Informaticae 102(2), 177207.
Luo, Z. (1994) Computation and Reasoning: A Type Theory for Computer Science. Oxford, UK: Oxford University Press.
McBride, C. (1999) Dependently Typed Functional Programs and their Proofs, PhD thesis, University of Edinburgh, Edinburgh, UK.
McBride, C. (2000) Elimination with a motive. In Types for Proofs and Programs (TYPES 2000), Durham, UK.
McBride, C., Goguen, H. & McKinna, J. (2006). A few constructions on constructors. In Types for Proofs and Programs (TYPES 2006), Nottingham, UK.
McBride, C. & McKinna, J. (2004) The view from the left. J. Funct. Program. 14 (1), 69111.
McBride, C. & Paterson, R. (2008) Applicative programming with effects. J. Funct. Program. 18 (1), 113.
Miller, D. (1992). Unification under a mixed prefix. J. Symb. Comput. 14, 321358.
Norell, U. (2007). Towards a Practical Programming Language Based on Dependent Type Theory, PhD thesis, Chalmers University of Technology, Sweden.
Peyton Jones, S., Vytiniotis, D., Weirich, S. & Washburn, G. (2006) Simple unification-based type inference for GADTs. In International Conference on Functional Programming (ICFP '06), vol. 41. New York, NY: ACM, pp. 5061.
Pollack, R. (1990). Implicit syntax. In Informal Proceedings of First Workshop on Logical Frameworks, Antibes. Citeseer.
Sozeau, M. & Oury, N. (2008) First-class type classes. In Theorem Proving in Higher Order Logics (TPHOLs 2008), Montreal, Canada, pp. 278293.
Vytiniotis, D., Peyton Jones, S., Schrijvers, T. & Sulzmann, M. (2011) OutsideIn(X) modular type inference with local assumptions. J. Funct. Program. 21 (4–5), 333412.

Idris, a general-purpose dependently typed programming language: Design and implementation

  • EDWIN BRADY (a1)


Altmetric attention score

Full text views

Total number of HTML views: 0
Total number of PDF views: 0 *
Loading metrics...

Abstract views

Total abstract views: 0 *
Loading metrics...

* Views captured on Cambridge Core between <date>. This data will be updated every 24 hours.

Usage data cannot currently be displayed

Idris, a general-purpose dependently typed programming language: Design and implementation

  • EDWIN BRADY (a1)
Submit a response


No Discussions have been published for this article.


Reply to: Submit a response

Your details

Conflicting interests

Do you have any conflicting interests? *