summaryrefslogtreecommitdiff
path: root/notes/250329-boot.md
blob: 37c3a488444aedd3d2a4398b7c4377719ad2d580 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# Bootstrapping Zisp

_2025 March_

In my opinion, any serious programming language must have a serious
bootstrapping strategy that addresses the "Trusting Trust" issue aka
the Thompson Hack.  The easiest way to do that is making sure that
your language can be bootstrapped from an existing language, which
itself has some solution to the problem.

Currently, I'm thinking of implementing Zisp in Zig.  (That's not the
entire reason Zisp is called Zisp, and I might choose a different
language eventually, and/or rename Zisp, but anyway.)

Zig, in turn, will *hopefully* be possible to bootstrap from C in the
future, or some language implemented in C.  For C, there are some ways
to bootstrap it from scratch.

## Partial self-hosting

_2025 December_

Currently thinking of the following strategy, which I believe is
similar to how Guile does it:

* There will be a Zisp interpreter written in Zig, which is fairly
  simple and naive in its implementation and, for example, ignores
  static type declarations.  It should support the full Zisp language
  including hygienic macros, but be as easy as possible to maintain.

* The Zisp compiler will be written in Zisp.  The interpreter can run
  the compiler (since it can run any Zisp program) and will be used to
  compile the compiler.