HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
coalton-lang
coalton
Common Lisp2021–2026
coalton-lang / coalton

coalton

Coalton is an efficient, statically typed functional programming language that supercharges Common Lisp.

32Distinct people
72Mentions
1Explicit recommenders
1.8KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

Coalton is an efficient, statically typed functional programming language that supercharges Common Lisp.

GitHub

Where it is used

No documented product use was verified in the last source check.

What people are saying

Coalton seems great, I love the idea. This issue seems problematic, though: https://github.com/coalton-lang/coalton/issues/84

dunefox used a recommendation phrase. One indexed comment matches. This is a phrase match, not a verdict.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

Mentioned in the same Hacker News threads. That is not proof they are substitutes.

This week on Hacker News

Nov 9–Nov 16 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/16/2026, 4:59:52 AM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year72 dated mentions

Observed mentions: 2021-10-27 01:30:41 UTC to 2026-07-10 17:19:00 UTC.

05101520252021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 5 mentions; 1 submissions, 4 comments20212022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 18 mentions; 3 submissions, 15 comments2023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 23 mentions; 1 submissions, 22 comments20232024-01-01 00:00:00 UTC to 2025-01-01 00:00:00 UTC (exclusive): 12 mentions; 1 submissions, 11 comments2025-01-01 00:00:00 UTC to 2026-01-01 00:00:00 UTC (exclusive): 10 mentions; 0 submissions, 10 comments2026-01-01 00:00:00 UTC to 2027-01-01 00:00:00 UTC (exclusive): 4 mentions; 1 submissions, 3 comments. Incomplete calendar period.2026*

* An incomplete calendar period is marked with an outlined bar. Its count is not directly comparable with a full period.

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC514
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC18315
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC23122
20242024-01-01 00:00:00 UTC2025-01-01 00:00:00 UTC12111
20252025-01-01 00:00:00 UTC2026-01-01 00:00:00 UTC10010
2026 (partial)2026-01-01 00:00:00 UTC2027-01-01 00:00:00 UTC413

From the project README

An excerpt from the repository, fetched Nov 13, 2026.

Read the project’s introduction
Coalton is an efficient, statically typed functional programming language that supercharges Common Lisp. Coalton integrates directly into Common Lisp: (defpackage #:differentiation (:use #:coalton #:coalton-prelude) (:local-nicknames (#:sym #:coalton/symbol)) (:export #:Expr #:EConst #:EVar #:E+ #:E*) (:export #:diff #:t #:d/dt)) (in-package #:differentiation) (named-readtables:in-readtable coalton:coalton) (coalton-toplevel ;; Define a new parametric algebraic data type for simple ;; mathematical expressions. (define-type (Expr :t) "A symbolic expression of basic arithmetic." (EConst :t) (EVar sym:Symbol) (E+ (Expr :t) (Expr :t)) (E* (Expr :t) (Expr :t))) ;; The classic `diff` function, in Coalton. (declare diff (Num :t => sym:Symbol * Expr :t -> Expr :t)) (define (diff x f) "Compute the derivative of `f` with respect to `x`." (match f ((EConst _) ; c' = 0 (EConst 0)) ((EVar s) ; x' = 1 (if (== s x) (EConst 1) (EConst 0))) ((E+ a b) ; (a+b)' = a' + b' (E+ (diff x a) (diff x b))) ((E* a b) ; (ab)' = a'b + ab' (E+ (E* (diff x a) b) (E* a (diff x b)))))) ;; We can use `t` just fine since Coalton doesn't import `cl:t`. (define t (sym:make-symbol "t")) (declare d/dt (Num :t => Expr :t -> Expr :t)) (define (d/dt f) "The time derivative operator." (diff t f))) It also works directly in the REPL: CL-USER> (in-package #:differentiation) DIFFERENTIATION> (coalton-toplevel (define (square x) (E* x x))) ;; SQUARE :: ∀ A. ((EXPR A) → (EXPR A)) DIFFERENTIATION> (coalton (d/dt (E+ (square (EVar t)) (EConst 1)))) #.(E+ #.(E+ #.(E* #.(ECONST 1) #.(EVAR |t|)) #.(E* #.(EVAR |t|) #.(ECONST 1))) #.(ECONST 0)) Type errors are discovered at compile-time, and errors are printed beautifully without sacrificing Common Lisp's interactive debugging facilities. DIFFERENTIATION> (coalton (d/dt (E+ (EConst 1/2) (EConst 0.5)))) error: Type mismatch --> repl:1:32 | 1 | (coalton (d/dt (E+ (EConst 1/2) (EConst 0.5)))) | ^^^^^^^^^^^^ Expected type '(EXPR FRACTION)' but got '(EXPR F32)' Coalton is currently used in production to build defense and quantum computing software. Getting Started WarningCoalton has not reached "1.0" yet. This means that, from time to time, you may have a substandard user experience. While we try to be ANSI-conforming, Coalton is currently only tested on recent versions of SBCL, Allegro CL, and Clozure CL. The version of Coalton that may be in Quicklisp may not be up-to-date. Prepare: Install SBCL (on macOS with Homebrew: brew install sbcl). Install Quicklisp by following instructions here. (The step command involving gpg is not needed.) After installing Quicklisp, you should have a quicklisp folder which will make installing Coalton easier. Install: Clone this repository into a place your Lisp can see (e.g., ~/quicklisp/local-projects/). Use: Either run (ql:quickload :coalton), or add #:coalton to your ASD's :depends-on list. Test: Compile the tests with (ql:quickload :coalton/tests), then run the tests with (asdf:test-system :coalton). NoteRunning the Coalton test suite on SBCL requires GNU MPFR in order to run Big-Float tests. If you would like to run tests without installing gnu-mpfr, you can use Coalton's portable Big-Float implementation by running (pushnew :coalton-portable-bigfloat *features*) before loading Coalton. Learn: Start with Whirlwind Tour of Coalton, the language manual, and the standard library reference, and then take a peek at the examples directory. It may also be helpful to check out the introductory blog post. Open Source Community: Awesome Coalton has a list of community-built libraries, applications, and examples, that you can use in your own projects or as examples to learn from. What's Here? This repository contains the source code to the Coalton compiler, and the standard library. It also contains two optional libraries, which are not loaded by default: coalton/xmath, for extended mathematics, and coalton/threads, for threads, synchronization, and parallel computation (SBCL only). It also contains a few example programs, such as: Some simple pedagogical programs, An implementation of Jones's Typing Haskell in Haskell, and An implementation of a simple Quil parser using parser combinators. Lastly and importantly, we maintain a collection of documentation about Coalton in the docs directory. Get Involved Want to ask a question about Coalton, propose a feature, or share a cool program you wrote? Try posting in the GitHub Discussions page! We welcome contributions of all forms, especially as we stabilize toward a 1.0 release. We would be grateful to receive: bug reports (filed as issues), bug fixes and typo corrections (filed as pull requests), small example programs, and user experience troubles.
Read the full README on GitHub

What Hacker News says

12 sources
I'm a big fan of lisps, and haven't played sufficiently with rust to have an opinion -- but I will note that the benefits of a sophisticated type system is qualitatively different from, say, the statically-typed environment of C or Objective-C. The comparison I make when thinking about CL is something like Haskell or Elm, which /do/ have that feel of "if it compiles, it works". Without that, I do have the feeling of working without a safety-net that pushes against that sense of freedom that dynamically-typed languages like CL otherwise offer. (Obligatory mention here of Coalton, which is an experiment in creating that sense of security within a CL paradigm: https://github.com/coalton-lang/coalton )
In The Liberating Experience of Common Lisp
> As someone who doesn't know much about types, do SBCL type declarations provide as good type-based development experience as OCaml and Rust? First of all, op was talking about strongly typed languages. Asking are they good as statically typed ones like Rust and OCaml is raising the goal posts quite a bit. Second of all, SBCL can indeed have a subsection of its code expressed in OCaml-like static types, see https://github.com/coalton-lang/coalton
In Optimizing Guile Scheme
Been interested in parser combinators for a while now but never really understood how people use them outside of toy examples (including watching this video multiple times). Are there any books like the popular compilers books that use them to build a language. Or is it just finding parsec implementations? I've been interested in Coalton lately, and I guess this is one of the examples, so maybe I've answered my own question. https://github.com/coalton-lang/coalton/tree/main/examples/q...
In Functional Parsing
A state of the art compiler [1] in quantum computing has not been rewritten in its 8 years of existence. This is accompanied by a quantum computer simulator that runs on the world's biggest supercomputers. [2] Multiple quantum computing companies use Common Lisp, and their software was written in a fraction of the time and resources taken for competing companies to do the same in either C++ or Python. Things like Coalton [3] really make Lisp stand out. What other language is able to add Haskell-quality types to their language? Lisp is not popular, so it doesn't have as much labor going into it, but for the work that does, remarkable results are achieved. Lisp does have a lot of the dubiously claimed power, but that power still requires reasonable engineering work to achieve—work that a lot of hobbyists are unwilling to do in their free 4
Read the rest
In Common Lisp Community Survey 2024 Results
The whole point of Lisp is to allow you, the programmer, to make the language that makes it easiest to write the program you're trying to write. Said language will be syntactic abstractions in Lisp primarily built out of Lisp macros, but there are additional means available to integrate your language idea into Lisp outside of macros. So, really, Lisp is in exact agreement with your position, with one proviso: Pick the language that makes it easiest to write the program you're trying to write—and express that language in Lisp. Case in point: Lisp does have a powerful type system that rivals Haskell. Full type inference, multi-parameter type classes, parametric polymorphism. It's called Coalton[1], and it's... just another Lisp library. Whether or not you can be bothered to spend the effort to align Lisp to your domain is another question,
Read the rest
but the mere fact it's both possible and reasonable to do is a testament to what some people mean by statements like "Lisp is powerful". [1] https://github.com/coalton-lang/coalton
In Ask HN: 30y After 'On Lisp', PAIP etc., Is Lisp Still "Beating the Averages"?
Common Lisp has bad marketing (even OCaml has Twitch streamers and "influencers" now), and bad support for general editors, both of which make it a non-starter for most curious people who have an afternoon to try something. But behind all that is magnificent activity for those who got over the initial potential energy barrier. Just to give some examples: 1. SBCL, the most popular open source implementation of Lisp, is seeing potentially two new garbage collectors, one of which is merged and open to beta testing. One of them is a parallel collector written by a university student (!!) which blows my mind. 2. SBCL has better and better support for deploying Lisp as a C-compatible shared library, using SBCL-LIBRARIAN. It makes it play nicer with other applications in C and Python, without the baggage of process wrangling and thick RPC (IPC/s
Read the rest
ervers, serialization, ...). 3. Coalton is another exciting development that allows a Haskell type system and "Lisp-1" functional programming in Common Lisp. That means type classes (or traits), something Lisp hasn't really had a proper notion of, and full type inference. Persistent sequences based off of RRB-trees were recently merged [1], and interestingly, they're implemented purely in Coalton [2]. That means Clojure-like seqs. It's interesting to see users of Lisp generating the above ideas and libraries, not a special in-group of committees, "official" developers, etc. [1] https://coalton-lang.github.io/reference/#seq-type [2] https://github.com/coalton-lang/coalton/blob/main/library/se...
In Embracing Common Lisp in the modern world

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.