Refine debug print-out.

This commit is contained in:
Stephen Chung
2021-04-06 23:18:41 +08:00
parent 7ec49a9510
commit f17a826f99
10 changed files with 219 additions and 123 deletions

View File

@@ -9,7 +9,7 @@ def_package!(crate:BasicFnPackage:"Basic Fn functions.", lib, {
mod fn_ptr_functions {
#[rhai_fn(name = "name", get = "name", pure)]
pub fn name(f: &mut FnPtr) -> ImmutableString {
f.get_fn_name().clone()
f.get_fn_name().as_str().into()
}
#[cfg(not(feature = "no_function"))]