diff --git a/src/eval/expr.rs b/src/eval/expr.rs index 35da7117..0a9558da 100644 --- a/src/eval/expr.rs +++ b/src/eval/expr.rs @@ -68,7 +68,9 @@ impl Engine { self.search_scope_only(global, caches, lib, level, scope, this_ptr, expr) } #[cfg(feature = "no_module")] - (_, (), ..) => self.search_scope_only(scope, global, lib, this_ptr, expr), + (_, (), ..) => { + self.search_scope_only(global, caches, lib, level, scope, this_ptr, expr) + } // Qualified variable access #[cfg(not(feature = "no_module"))] diff --git a/src/module/mod.rs b/src/module/mod.rs index 68ef16e3..6cb59198 100644 --- a/src/module/mod.rs +++ b/src/module/mod.rs @@ -3,7 +3,6 @@ #[cfg(feature = "metadata")] use crate::api::type_names::format_type; use crate::ast::FnAccess; -use crate::eval::Caches; use crate::func::{ shared_take_or_clone, CallableFunction, FnCallArgs, IteratorFn, RegisterNativeFunction, SendSync, @@ -1985,7 +1984,7 @@ impl Module { let orig_constants = std::mem::take(&mut global.constants); // Run the script - let caches = &mut Caches::new(); + let caches = &mut crate::eval::Caches::new(); let result = engine.eval_ast_with_scope_raw(global, caches, 0, &mut scope, ast);