omg_runtime 0.1.4

The OMG language runtime and virtual machine, providing bytecode execution, REPL, and built-in functions.
Documentation
//! Public library API for the OMG runtime.
//!
//! This exposes the VM, bytecode loader, and core types so downstream
//! crates can embed the runtime or run precompiled bytecode.

pub mod bytecode;
pub mod error;
pub mod repl;   // optional to expose
pub mod value;
pub mod vm;

// Re-exports for convenience
pub use crate::bytecode::{parse_bytecode, Function, Instr};
pub use crate::error::{ErrorKind, RuntimeError};
pub use crate::value::Value;
pub use crate::vm::run;

/// Run a compiled `.omgb` blob with optional program args.
pub fn run_omgb(bytecode: &[u8], program_args: &[String]) -> Result<(), RuntimeError> {
    let (code, funcs) = parse_bytecode(bytecode);
    run(&code, &funcs, program_args)
}