Code cleanup

This commit is contained in:
Stephen Chung
2020-11-25 09:36:06 +08:00
parent 05d51ef510
commit a0979d0c35
19 changed files with 187 additions and 160 deletions

View File

@@ -5,7 +5,7 @@ use crate::{calc_script_fn_hash, def_package, FnPtr, ImmutableString, NativeCall
#[cfg(not(feature = "no_function"))]
#[cfg(not(feature = "no_index"))]
#[cfg(not(feature = "no_object"))]
use crate::{module::SharedScriptFnDef, stdlib::collections::HashMap, Array, Map};
use crate::{ast::ScriptFnDef, stdlib::collections::HashMap, Array, Map};
def_package!(crate:BasicFnPackage:"Basic Fn functions.", lib, {
combine_with_exported_module!(lib, "FnPtr", fn_ptr_functions);
@@ -54,7 +54,7 @@ fn collect_fn_metadata(ctx: NativeCallContext) -> Array {
fn make_metadata(
dict: &HashMap<&str, ImmutableString>,
namespace: Option<ImmutableString>,
f: SharedScriptFnDef,
f: &ScriptFnDef,
) -> Map {
let mut map = Map::with_capacity(6);