Skip to content
This repository has been archived by the owner on May 15, 2021. It is now read-only.

chikaku/nad

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Nad

Incomplete Lua VM only bytecode is supported for now

Usage

  • Dump function prototype
cargo run -- -dump -debug /path/to/bytecode
# or
cargo install nad
nad -debug -dump /path/to/bytecode
  • Execute bytecode file
cargo run -- -debug /path/to/bytecode
# or
cargo install nad
nad -debug /path/to/bytecode
  • Use nad library
use nad::State;
use nad::Reader;

fn main() {
    let path = "/path/to/bytecode";
    
    // read prototype
    let prototype = Reader::from_file(path).prototype();
    
    // execute main function
    State::from_file(path).call(0, 0);
}

TODO

  • Metatable
  • Iterator
  • Error handler
  • ...

About

Incomplete Lua VM written in Rust

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published