EZC is a concatenative, postfix, stack-based esolang implemented in Rust.
src/ezclang/: language frontend (tokenizer,parser)src/ezcbc/: EZC bytecode compiler/ISAsrc/ezcvm/: EZC virtual machine runtimeezcweb/: standalone Dioxus WASM docs/playground cratedocs/: EZC language source of truthtest/: EZC source-code fixtures used by tests
cargo run -- run demo/square.ezc
cargo run -- run demo/hello.ezc
cargo run -- run demo/fib.ezc
cargo run -- run demo/gcd.ezc
cargo run -- run demo/factorial.ezc
cargo run -- run demo/powers_of_two.ezc
cargo run -- run demo/triangular.ezc
cargo run -- disasm demo/loop_countdown.ezc
cargo run -- check demo/substack.ezc
cargo run -- eval "(5 dup * prt)!"
cargo run -- replREPL controls:
:helpshow commands:clearclear transcript:quitexit the session
Verbose intermediate stages:
cargo run -- --verbose run demo/loop_countdown.ezccargo test
cargo check --workspace
cargo check -p ezcwebDeployment infra is managed in infra/ using OpenTofu/Terraform.
- Cloudflare Pages project is configured for this repo.
- Custom domain target is
ezc.cade.io.
Quick start:
cd infra/cloudflare
cp terraform.tfvars.example terraform.tfvarsSet account_id, github_owner, and export your API token:
export CLOUDFLARE_API_TOKEN="..."
tofu init
tofu plan
tofu applyThis repo intentionally does not use GitHub Actions deployment.
Cloudflare build tooling bootstrap uses infra/cloudflare/pages_build.sh with
cargo-binstall fast-path and cargo install fallback.
Run it from the web crate:
cd ezcweb
dx serveOr from repo root:
dx serve -p ezcweb --webIf you want a different port (recommended in this repo to avoid 8080 collisions):
cd ezcweb
dx serve --port 4310The webapp is route-based:
/: landing page with high-level overview and runnable samples/repl: full-screenxterm.jsterminal, persistent VM stack, command history/docs:docs/language.mdrendered with runnable snippets/book: chapter index for the learning walkthrough/book/:slug: chapter pages with previous/next navigation
The web bundle is self-contained for static hosting: terminal assets are vendored (no CDN runtime fetches).
rustup target add wasm32-unknown-unknown
cargo install dioxus-cli --version 0.7.2 --locked
cargo install wasm-bindgen-cliBuild static output:
cd ezcweb
dx build --release
python3 -m http.server --directory ../target/dx/ezcweb/release/web/public 8080Vendored web dependencies:
ezcweb/assets/vendor/xterm/xterm.jsezcweb/assets/vendor/xterm/xterm.css