Custodian is a simple Lua implementation of Option and Result types available in other languages' standard libraries, such as Rust. It uses a functional programming paradigm for simplicity and explicitness.
- The
Option<T>
type can be used to represent an optional value without making assumptions about whether the value isnil
. - The
Result<T, E>
type can be used to improve the ergonomics of error handling in your application by incorporating success/failure and returned value in a single variable.
- Set up a Wally project.
- Add Custodian as a dependency in your
Wally.toml
file. - Run
wally install
.
🎉 Congratulations! You've installed Custodian.