opd-lang
my own programming language. so far it has a working lexer and the start of a parser.
2026-09-01 | building
i wanted to know what actually happens when code runs. the best way i know to find out is to build the thing that runs it.
i'm following tyler laceby's beginner series on building interpreters, in typescript on deno. it's small so far, under 200 lines. the lexer works: give it let x = 25 * (3 / 4) and it breaks it into tokens.
deno run lexer.ts
{ value: "let", type: 2 }
{ value: "x", type: 1 }
{ value: "=", type: 4 }
{ value: "25", type: 0 }
{ value: "*", type: 3 }
{ value: "(", type: 5 }
{ value: "3", type: 0 }
{ value: "/", type: 3 }
{ value: "4", type: 0 }
{ value: ")", type: 6 }
{ value: "EndOfFile", type: 7 }the syntax tree's node types are written, but the parser is still a skeleton: the functions that actually build the tree are empty.
- lexer
- syntax tree node types
- parser
- interpreter, so it actually computes something
- functions
- error messages that tell you what you did wrong
it's on pause for the next two or three months. i want to build my inference engine first, then i'll come back to the parser.