diff --git a/README.md b/README.md index a02a84fa..2ea9a228 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ Rhai's current feature set: * No additional dependencies * No unsafe code -**Note:** Currently, it's version 0.5.1, so the language and APIs may change before they stabilize.* +**Note:** Currently, it's version 0.6.2, so the language and APIs may change before they stabilize.* ## Installation @@ -20,7 +20,7 @@ You can install Rhai using crates by adding this line to your dependences: ``` [dependencies] -rhai = "0.5.1" +rhai = "0.6.2" ``` ## Related diff --git a/src/engine.rs b/src/engine.rs index a7a898bd..a67ea15e 100644 --- a/src/engine.rs +++ b/src/engine.rs @@ -106,6 +106,7 @@ pub enum FnType { /// } /// ``` pub struct Engine { + /// A hashmap containing all functions know to the engine pub fns: HashMap>, } diff --git a/src/fn_register.rs b/src/fn_register.rs index b0b63e52..d6d062f8 100644 --- a/src/fn_register.rs +++ b/src/fn_register.rs @@ -3,7 +3,10 @@ use std::boxed::Box; use engine::{EvalAltResult, Engine, FnType}; +/// A trait used for registering functions to an Engine +/// Currently, Rhai supports functions with up to 6 parameters pub trait FnRegister { + /// A method used for registering functions and methods to a Engine fn register_fn(&mut self, name: &str, f: A); }