core.typed is an optional type system for Clojure.


(clojure.core.typed/ann v t) gives var v the static type t.

(clojure.core.typed/ann-form f t) ensures form f is of the static type t.

(clojure.core.typed/check-ns) type checks the current namespace.

(clojure.core.typed/cf t) type checks the form t.

See the Quick Guide.


Why core.typed exists, what can it do for you?

Getting Started Guide

If you are new to core.typed, gradual type systems, or even types in general, and want to learn how core.typed can help verify your programs, start here.

Introduction and Motivation

We discuss some theory and design goals of core.typed.


Where and how to annotate your code to help core.typed check your code.


Syntax and descriptions of core.typed types.

Polymorphic Functions, Bounds and Higher-kinded Variables


An overview of filters for occurrence typing.

Datatypes and Protocols

Typing definitions and usages of Clojure datatypes and protocols.

Looping constructs

core.typed provides several wrapper macros for common looping constructs.

Dotted Functions

Java Classes, Arrays and Interop

Miscellaneous Tutorials

Hole-Driven Development

A fun diversion playing with holes.

  • Requires some knowledge of Haskell.



Limitations - Known issues

Documentation Contributors

Ambrose Bonnaire-Sergeant (@ambrosebs)

Copyright 2013, Ambrose Bonnaire-Sergeant