🍖 ham, a programming language made in Rust
NOTE: I'm learning rust, I am still a noob
status: alpha
You can download it from here.
- Speed
- Security
- Comfort
- Rust interoperability
- Manifest file
- Ability to import files from:
- Local file system
- HTTP urls
- By name (this would use some kind of remote registry to translate it to HTTP urls)
- std library
- Low-level (networking, file system...) APIs
- CD integration to release a new version in each commit
- More unit tests
fn calc(value){
// If the value is 5 end the function
if value == 5 {
return 0
}
// Add 1
value.mut_sum(1)
// Print it's value
println(format("Value is {}", value))
// Call the function again with the latest value
return calc(value)
}
// This will print from `Value is 1` to `Value is 5`
let _ = calc(0)There are more examples in /examples.
ham is a general purpose language. It is heavily inspired by Rust and TypeScript.
Built-in repl:
ham replRun files:
ham run examples/demo.hamRun a project (This will run 1_project/src/main.ham automatically):
ham run examples/1_projectCompiling:
cargo build --releaseLinting:
cargo clippyFormatting:
cargo fmtTesting:
cargo testInstall mdbook:
cargo install mdbookBuild the book:
mdbook buildWatch for changes on the book:
mdbook watchRunning directly:
cargo run -- run examples/demo.hamMade by Marc Espín Sanz
MIT License