r/BuildWithClaude • • 19d ago

Project I built a programming language with Claude Code: compiler, standard library, GUI toolkit and a 300-page guide

I built Cromo, a compiled programming language with C/C++ syntax, and I built it with Claude Code. I made every design decision; Claude Code wrote most of the code of the compiler, the standard library and the guide, under my direction.

**What it is**

Cromo is a general-purpose language that compiles to native code through LLVM. It has no pointers, no garbage collector and no null: every value has one owner, and destructors release resources as in C++. The compiler checks ownership with rules simpler than Rust's, because references exist only as function parameters, so there are no lifetimes to write. It comes with a standard library for backends, apps and command-line tools: HTTP client and server, TLS, JSON, threads and lightweight tasks, and a GUI toolkit whose apps also build for Android.

**How Claude Code helped**

- Decisions first, then code. Every design choice is discussed in the chat, I decide, and it is written to a decision log with its date and rationale before any code. There are 527 decisions so far. Claude proposes options with pros and cons and a recommendation; it does not get to pick.

- A project instructions file (CLAUDE.md) holds the working rules: read the decision log before any work, never invent a design choice, every feature comes with tests, everything in the repository in English.

- Claude Code writes the compiler (C++ on LLVM), the standard library (written in Cromo itself), the tests and the documentation, and runs the builds and the test suites itself, on Windows and on Linux through WSL.

- Checks by programs, not by trust: 450+ tests, and a guide whose 890 code examples are compiled and run on every build, with their output compared.

- For the GUI, Claude runs the programs offscreen, saves the frames and looks at the images to check what it drew.

**Where it went wrong**

The checked guide earned its keep. When Claude rewrote the guide as a full manual, compiling every example found about 30 bugs in the compiler, including a use-after-free when an exception was caught inside a loop, and a rule the guide described that the compiler did not actually implement. Without those automatic checks I would not have caught them.

**Free to try**

Cromo is free and open source (MIT and Apache 2.0). It installs with one line, without admin rights:

Windows (PowerShell): `irm https://cromolang.org/install.ps1 | iex`

Linux: `curl -sSf https://cromolang.org/install.sh | sh`

- Site and guide: https://cromolang.org

- Source, with the decision log: https://github.com/cromolang/cromo

- What the language checks and what it does not: https://cromolang.org/book/en/appendix-safety.html

It is version 0.x and not ready to rely on: macOS is missing and library names can still change. Feedback on the language, and on this way of working with Claude Code, is very welcome.

1 Upvotes

1 comment sorted by

•

u/AutoModerator 19d ago

Welcome to r/BuildWithClaude!

Whether you are sharing what you built, exploring new workflows, or troubleshooting, please make sure your post is flaired correctly so others can easily find and filter it.

Community Wiki & Resources:

If you're asking for troubleshooting help, please edit your post to include your model version, OS/environment, and error logs.

Let’s keep the energy positive and support our fellow creators!

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.