
Phase — a statically-typed bytecode-interpreted language in C, with an essay on implementation
Phase is a statically-typed bytecode-interpreted programming language written in ~4,800 lines of C with zero external dependencies. It features a 25-opcode stack-based VM, 21 error types with source-mapped diagnostics, 5 primitive types, and a standard interpreter pipeline (lexer, parser, type checker, bytecode generator, VM).
I also wrote a technical piece on how it works by following out("Hello world!") end-to-end through every stage.
Writing: williamalexakis.com/interpreter-in-c
u/williamalexakis — 1 day ago