work
This commit is contained in:
@@ -7,6 +7,13 @@ mod ir;
|
||||
mod parser;
|
||||
|
||||
fn main() {
|
||||
parser::main();
|
||||
let arg = std::env::args_os().nth(1);
|
||||
if let Some(path) = arg {
|
||||
let file = std::fs::read_to_string(path).expect("failed to read file");
|
||||
println!("{file}");
|
||||
parser::parse_file(&file);
|
||||
} else {
|
||||
parser::run_stdin();
|
||||
}
|
||||
// compiler::main();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user