Creative case study
Lish Programming Language
An educational compiler project translating academic Computer Science theory into a working plain-English general-purpose compiler that compiles directly to zero-overhead x64 assembly.
Creative case study
An educational compiler project translating academic Computer Science theory into a working plain-English general-purpose compiler that compiles directly to zero-overhead x64 assembly.
Client
Academic & Language Research
Role
Language Architect & Developer
Year
2026
Discipline
Compiler Engineering & Programming Language Design
Doodle concept visualImplemented a full general-purpose compiler toolchain to learn how high-level readable instructions translate directly to CPU registers and machine instructions.
The hero image is loaded from the MDX coverImage field. Replace the demo URL with your own gameplay capture, PixiJS canvas screenshot, or rendered artwork.
High-to-Low Translation
Learning Focus
Recursive Descent (AST)
Parser Type
Automata & Grammars
CSE Application
In a typical Computer Science & Engineering (CSE) curriculum, compiler design and automata theory are often taught as dense mathematical abstractions. Students memorize state machines, context-free grammars (CFGs), and register allocation algorithms, but rarely get to build a working general-purpose programming language compiler from scratch.
Lish (Language of Intent and Software Harmony) was created to bridge this academic gap. The core aim of the project was learning by building: taking the compiler theory taught in university degrees and applying it to a concrete, high-performance general-purpose language toolchain.
By designing a general-purpose language that reads like standard English but compiles directly to low-level x64 machine code, the project served as a hands-on vehicle to learn exactly how high-level logic and modern language features are parsed, optimized, and executed by hardware.
Building Lish required putting classical Computer Science concepts into practical action:
Academic theory teaches that lexers use Finite State Automata (FSA) to convert characters into logical tokens. In Lish, this concept was applied to parse natural English text. The compiler identifies keywords like let, be, and repeat, while dynamically filtering out superficial grammar words (like "the", "to", "please") that humans use for readability but computers do not need.
Lish translates natural sentences into structured data by implementing a Context-Free Grammar. The parser processes tokens into an Abstract Syntax Tree (AST) using a recursive descent parser. This tree maps parent-child relationships between operators and operands, converting linear text into a hierarchy of execution.
[Assignment Node]
/ \
[Variable: age] [Constant: 25]
One of the key learning milestones of Lish was understanding how compilers bridge the distance between frontends (what the developer writes) and backends (what the machine runs). Lish uses LLVM Intermediate Representation as a type-safe buffer, allowing the compiler to perform general optimizations before target code emission.
A central objective of the Lish project was understanding how low-level registers and memory segments function. Here is how high-level statements are converted to assembly instructions:
When writing variables and arithmetic in Lish:
let a be 10
let b be 20
let result be a + b
The compiler translates this high-level code into three main compiler actions:
a and b to CPU registers EAX and EBX.add instruction.mov eax, 10 ; Load literal 10 into register EAX
mov ebx, 20 ; Load literal 20 into register EBX
add eax, ebx ; Perform hardware addition
mov [result], eax; Store calculated sum in memory offset
By outputting pure assembly, the project illustrates how simple CPU operations form the execution engine behind complex human logic in a modern, general-purpose language.
The Lish project shows that compilers are not magical black boxes. By applying university-level Computer Science algorithms — from tokenizers and parsing trees to code emission and register constraints — Lish demonstrates how to design a modern, general-purpose language that prioritizes human expression without sacrificing low-level machine efficiency.
More Case Studies
A technical deep-dive into how production iGaming studios store, version, and serve complex game math configurations across operators, jurisdictions, and variants.
A complete blueprint of an enterprise iGaming backend system: from the Seven-Layer Model and 48ms game transaction loops to GLI compliance and scaling pipelines.
A cinematic, AI-driven 'Command Center' featuring intelligent site control, predictive autocomplete, and hardware-accelerated animations built with Next.js 15.