Fix builds.

This commit is contained in:
Stephen Chung
2022-08-18 21:16:42 +08:00
parent 83589be58e
commit a9b6e8b98c
12 changed files with 80 additions and 56 deletions

View File

@@ -83,6 +83,7 @@ pub trait Package {
///
/// package.register_into_engine_as(&mut engine, "core");
/// ```
#[cfg(not(feature = "no_module"))]
fn register_into_engine_as(&self, engine: &mut Engine, name: &str) -> &Self {
Self::init_engine(engine);
engine.register_static_module(name, self.as_shared_module());