Safe mruby bindings for Rust that enable embedding Ruby code and testing Rust structs with a restricted API.
mrusty is a Rust library that provides safe bindings to mruby, allowing developers to embed Ruby code within Rust applications. It enables running Ruby 1.9 files with a restricted API and reflects Rust structs and enums in mruby for execution, all while maintaining safety and ease of use.
Rust developers who need to embed Ruby scripting capabilities, create domain-specific languages, or add testing frameworks to their applications.
Developers choose mrusty for its safe integration between Rust and mruby, automatic type conversion, built-in spec testing, and REPL support, making it a robust solution for embedding Ruby in Rust projects.
mruby safe bindings for Rust
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Automatically converts between Rust and mruby types safely, as shown in the def! macro examples, reducing manual boilerplate and preventing type errors.
Allows running Ruby 1.9 files directly within Rust apps using a restricted API, eliminating the need for a separate Ruby installation.
Provides a testing framework to write and run specs on Rust types reflected in mruby, facilitating behavior-driven development.
Includes a REPL for experimenting with mruby in Rust contexts, enhancing development and debugging workflows.
Only supports a subset of Ruby 1.9 features with a very restricted API, limiting the complexity of scripts that can be embedded.
Embedding the mruby interpreter introduces runtime overhead compared to native Rust execution, which may not be suitable for performance-critical applications.
mruby has a smaller community and fewer libraries than full Ruby, reducing the availability of pre-built gems and resources.
Requires the use of macros like mrusty_class! and def!, which can add complexity to the codebase and have a learning curve.