The Design Principles of the Elixir Type System


This talk will present the current state of Guillaume Duboc’s PhD thesis on introducing a type system to Elixir. We will present set-theoretic types, and how they are uniquely suited to represent Elixir programs. Then, we will showcase the potential benefits of a type system designed for Elixir, such as detecting common bugs and providing direct feedback on code quality.

In addition to exploring the use of types to describe and enforce function interfaces, we will provide examples of new syntax for types that could be added to the language. We will also delve into the concept of gradual typing and its ability to mix typed and untyped code, as well as ease the optional transition of existing codebases towards types.

We will share my perspective on the state of the project, the forthcoming work, and the challenges we have faced, as this is joint work with Giuseppe Castagna and José Valim.

Key Takeaways:

  • Showcase the potential benefits of a type system for the programmer
  • Understand what kind of types can describe Elixir programs.

Target Audience:

  • Any Elixir programmer

Types, Set-theoretic, Tooling