Ndebele Programming Languge written in Rust
# Qho
A small programming language built in Rust, with a syntax inspired by the Ndebele language. This project was built as an experiment using Kiro — pushing the limits of what an AI-assisted IDE can help you build from scratch in a single session.
---
## Getting Started
### Prerequisites
- Rust (edition 2024)
### Build
```bash
cargo build --release
```
The binary will be at `target/release/qho.exe` (Windows) or `target/release/qho` (Linux/macOS).
### Run a file
```bash
./target/release/qho myprogram.ndebele
```
Files must have the `.ndebele` extension.
---
## The Language
### Keywords
| Keyword | Meaning |
|---|---|
| `bhala` | print to console |
| `inombolo` | number type (float64) |
| `ibala` | string type |
| `yenza` | generic value binding (sockets, listeners, etc.) |
| `uma` | if |
| `phindaUma` | while loop |
| `phinda` | infinite loop (like Rust's `loop`) |
| `phuma` | break |
| `qhubeka` | continue |
| `isigoqelo` | function |
| `isakhi` | struct |
| `bumba` | instantiate a struct |
| `mina` | self (inside methods) |
| `phendukisa` | return |
| `akulalutho` | null value |
### Variables
```js
inombolo iminyaka = 25;
ibala ibizo = "Tawanda";
yenza conn = TCP::xhumana("127.0.0.1:8080");
```
### Functions
```js
isigoqelo bingelela(name: ibala) {
bhala("Sawubona,");
bhala(name);
}
bingelela("Tawanda");
```
### Structs and Methods
```js
isakhi Server {
ibala IP
inombolo port
isigoqelo qala() {
bhala("Starting on:");
bhala(mina.IP);
}
}
bumba Server s;
s.IP = "127.0.0.1";
s.port = 8080;
s.qala();
```
### Control Flow
```js
uma (x > 5) {
bhala("greater than 5");
}
phindaUma (x `, ` =`
---
## Networking (TCP)
All networking functions are built-in — no imports needed.
| Function | Description |
|---|---|
| `TCP::lalela(addr)` | Bind and listen on an address |
| `TCP::yamukela(listener)` | Accept an incoming connection |
| `TCP::xhumana(addr)` | Connect to a remote server |
| `TCP::funda(stream)` | Read a line from a stream (returns `a …