Planned Type System


Passerine’s Type System

Passerine has full support for algebraic data types. It’s structurally typed with support for type refinement at runtime. Passerine’s type system aims to be decidable and sound.

Core Algebraic Data Types

Atoms

Base types that can not be broken down. This includes:

Records

product types over a set of fields:

Unions

sum types over a set of types:

Lists

Homogenous growable array of items of a type:

Labels

Scoped namespaces to distinguish types with different semantics of the same structure. They must be defined with the type keyword: