Rename Imports to GlobalRuntimeState.

This commit is contained in:
Stephen Chung
2021-12-28 11:42:52 +08:00
parent 9deddc679c
commit 807240e249
9 changed files with 112 additions and 84 deletions

View File

@@ -15,11 +15,11 @@ pub struct ScriptFnDef {
pub body: StmtBlock,
/// Encapsulated running environment, if any.
pub lib: Option<Shared<Module>>,
/// Encapsulated [`GlobalRuntimeState`][crate::GlobalRuntimeState].
/// Encapsulated stack of imported modules, if any.
///
/// Not available under `no_module`.
#[cfg(not(feature = "no_module"))]
pub global: crate::engine::GlobalRuntimeState,
pub global: Option<Box<[(Identifier, Shared<Module>)]>>,
/// Function name.
pub name: Identifier,
/// Function access mode.