Sila Dev Log: Rewriting in Coalton
Posted on 25th of August 2025 | 510 wordsPlug: Follow the Sila development here. |
Some time ago, I was quite actively working on my very own compiler project whenever I had some spare time. Unfortunately, due to personal time constraints, this project has been on the back-burner for a while. I have recently started writing and recording a new solo music project, which has taken a good chunk of my time.
Have been diving quite deeply into Opusmodus for composing and analyzing music, a beautiful example of what Common Lisp can enable in creative domains.
Another reason for the pause was that I had coded myself a little bit into a corner, mostly due to early architectural decisions that didn’t scale well. At one point, I even attempted a refactor. Thankfully, the codebase was still relatively small, but even then, it proved to be a frustrating experience.
A big part of that frustration came from the dynamic nature of Common Lisp, which, at least in my personal experience, made larger-scale refactoring feel “unnecessarily” difficult. Of course, I fully admit this is largely a skill issue, not an inherent flaw of the language. I still love Lisp. Its flexibility, its macro system, and its directness are all things I deeply value.
That said, I’ve been feeling the itch to return to more hands-on, low-level programming, especially with all the noise around AI agents, LLMs, and increasingly abstracted tools. Watching the landscape shift so rapidly, I’ve found myself wanting to ground myself again in real systems. To work with code that’s close to the metal, conceptually speaking. A compiler project in Common Lisp still feels like one of the best ways to do that.
There was a moment when I considered switching the project to another language, something statically typed, like Haskell. But for me, despite appreciating Haskell and especially its contributions to PLT, it doesn’t really spark similar joy as programming Common Lisp does.
Now I do think Haskell offers something great in the form of its type system, which then made me into start looking at Coalton, which is essentially programming language that lives in the userspace of Common Lisp supercharging it by providing static typing to your regular Common Lisp programming.
I’ve been following Coalton’s development quite closely since its deception, mainly due to the fact that it’s original author, Robert Smith, is quite vocal evangelist for it. And for reason! But I never really had a project where I could start actually using it. So I thought to myself that why not start testing it in my compiler. Considering the fact that it resembles Haskell quite closely and Haskell and it’s type system is a relatively good platform for implementing compilers, that would mean Coalton would also be the same! Maybe.
So, this is a fresh start, but also a continuation. A personal reboot.
I’m back to working on the compiler again, in Common Lisp (or Coalton), and I plan to start posting regular updates. If you’re interested in programming languages, compiler internals, or just enjoy seeing how things evolve over time, feel free to follow along.
Let’s see where this leads.
NB: If you want to read earlier posts of this dev log, head over here. |