Files
clox/README.md
Daniel Henry 495545ef22 Finish Chapter 16
Implement basic parsing / scanner

Signed-off-by: Daniel Henry <iamdanhenry@gmail.com>
2025-08-22 03:43:08 -05:00

46 lines
789 B
Markdown

# clox — Crafting Interpreters (clox, C)
A tiny bytecode VM + compiler for the Lox language, built while following *Crafting Interpreters*. This is a personal learning project.
Crafting Interpreters: https://craftinginterpreters.com/
## Build
Requires a C99 compiler (tested with `clang` on macOS). Uses the provided Makefile.
```sh
# Build the executable to bin/clox
make
# Clean build artifacts
make clean
# Show discovered sources/objects (diagnostic)
make debug
# (Optional) regenerate compile_commands.json for clangd/etc.
make bear
```
## Usage
Run a file
```sh
clox [file]
```
Run Repl
```sh
clox
```
## Layout
```
include/ # headers (.h files)
src/ # source (.c files)
obj/ # build objects (generated)
bin/ # executable output (generated)
```