Get rid of virtual machine code

Gonna implement this differently
This commit is contained in:
greg 2017-10-02 20:34:51 -07:00
parent abbbb34901
commit 1aa4e3b942
2 changed files with 0 additions and 31 deletions

View File

@ -29,12 +29,8 @@ mod language;
use language::{ProgrammingLanguageInterface, EvalOptions, LLVMCodeString};
mod webapp;
mod llvm_wrap;
mod virtual_machine;
use virtual_machine::{run_vm, run_assembler};
fn main() {
let languages: Vec<Box<ProgrammingLanguageInterface>> =
vec![
@ -63,18 +59,6 @@ fn main() {
std::process::exit(0);
}
if option_matches.opt_present("m") {
let file_name = option_matches.free.get(1);
run_vm(file_name);
std::process::exit(0);
}
if option_matches.opt_present("a") {
let file_name = option_matches.free.get(1);
run_assembler(file_name);
std::process::exit(0);
}
if option_matches.opt_present("w") {
webapp::web_main();
std::process::exit(0);
@ -366,12 +350,6 @@ fn program_options() -> getopts::Options {
options.optflag("h",
"help",
"Show help text");
options.optflag("m",
"virtual-machine",
"Start up a virtual machine instead of an interpreter");
options.optflag("a",
"assembler",
"Assemble file into bytecode");
options.optflag("w",
"webapp",
"Start up web interpreter");

View File

@ -1,9 +0,0 @@
pub fn run_vm(file_name: Option<&String>) {
println!("Running in VM mode");
println!("yy: {:?}", file_name);
}
pub fn run_assembler(file_name: Option<&String>) {
println!("Assembling file");
println!("yy: {:?}", file_name);
}