Add strings example.
This commit is contained in:
@@ -179,13 +179,14 @@ A number of examples can be found in the `examples` folder:
|
||||
|
||||
| Example | Description |
|
||||
| ------------------------------------------------------------------ | --------------------------------------------------------------------------- |
|
||||
| [`arrays_and_structs`](examples/arrays_and_structs.rs) | demonstrates registering a new type to Rhai and the usage of [arrays] on it |
|
||||
| [`custom_types_and_methods`](examples/custom_types_and_methods.rs) | shows how to register a type and methods for it |
|
||||
| [`arrays_and_structs`](examples/arrays_and_structs.rs) | shows how to register a custom Rust type and using [arrays] on it |
|
||||
| [`custom_types_and_methods`](examples/custom_types_and_methods.rs) | shows how to register a custom Rust type and methods for it |
|
||||
| [`hello`](examples/hello.rs) | simple example that evaluates an expression and prints the result |
|
||||
| [`no_std`](examples/no_std.rs) | example to test out `no-std` builds |
|
||||
| [`reuse_scope`](examples/reuse_scope.rs) | evaluates two pieces of code in separate runs, but using a common [`Scope`] |
|
||||
| [`rhai_runner`](examples/rhai_runner.rs) | runs each filename passed to it as a Rhai script |
|
||||
| [`simple_fn`](examples/simple_fn.rs) | shows how to register a Rust function to a Rhai [`Engine`] |
|
||||
| [`simple_fn`](examples/simple_fn.rs) | shows how to register a simple function |
|
||||
| [`strings`](examples/strings.rs) | shows different ways to register functions taking string arguments |
|
||||
| [`repl`](examples/repl.rs) | a simple REPL, interactively evaluate statements from stdin |
|
||||
|
||||
Examples can be run with the following command:
|
||||
|
Reference in New Issue
Block a user