Skip to content

Commit afdd147

Browse files
committed
Add new blog post (write a compiler)
1 parent 747fefd commit afdd147

1 file changed

Lines changed: 51 additions & 0 deletions

File tree

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
---
2+
draft: false
3+
date: 2026-02-26
4+
categories:
5+
- python
6+
slug: 202602-write-a-compiler
7+
description: Write a Compiler course with David Beazley
8+
---
9+
10+
# Write a Compiler (with David Beazley)
11+
12+
Every year I tend to take a course somewhere — the topics are quite diverse,
13+
ranging from applied math to psychology (it's fun and helps me stay sharp). Normally I
14+
choose something in Stanford or MIT but this year I stumbled upon the [Write a
15+
Compiler](https://dabeaz.com/compiler.html) course by David Beazley and I couldn't
16+
resist. I must say, a week is a long enough period to show you what you are made of ...
17+
18+
<!-- more -->
19+
20+
It was intense &mdash; even though I ended up using Python[^1] to complete the projects!
21+
22+
The course hours were between 9:30am and 5:30pm US Central Time/Chicago, while I was
23+
taking it from France (so, between 4:30pm and 12:30am local time for me). As I suspected
24+
what would happen, I kicked my kids out for a week (there are many advantages of being
25+
divorced). I guess a "bachelor coding week" is a good description of what happened
26+
&mdash; it took me 16 hours of coding a day to keep up with the pace (and I am veeery
27+
comfortable with Python, tree recursion etc.)! Coming to think of it, I might have
28+
forgotten to take a shower during the course.
29+
30+
## A typical day
31+
32+
I start coding around 7am (local time in France), a quick lunch, continue coding until
33+
3pm, take a nap for an hour or so, then join Zoom and of we go, super engaging
34+
discussions (geeky comments and ideas). Around 8pm there is a break and I have dinner (I
35+
take my time to prepare something nice). We continue working and around 10pm I start
36+
losing steam. I mostly listen to the discussion and go to sleep. The next day I catch-up
37+
in the morning (when I am fresh) ...
38+
39+
## The end result
40+
41+
I was able to have a working compiler for the Wab language by the end of day four and
42+
started working on Wabbi. Now I plan to repeat the process using Rust and then look into
43+
Wabbit and types.
44+
45+
This was such a treat! The course was organized flawlessly (I must admit that I have
46+
stolen some ideas for my courses). I really enjoyed the challenge and learned many
47+
things. **Having independent educators like this is a gift**.
48+
49+
Thanks Dave!
50+
51+
[^1]: Initially, I was considering using Rust or Racket.

0 commit comments

Comments
 (0)