ft(interpreter): impl simple stack init
This commit is contained in:
14
src/main.rs
14
src/main.rs
@@ -36,11 +36,23 @@ struct Args {
|
||||
/// Dump progress of disassembly, in case of encountering an error.
|
||||
#[arg(short, long, global = true, action)]
|
||||
dump: bool,
|
||||
|
||||
/// argv passed to the program, which will be interpreted
|
||||
#[arg(trailing_var_arg = true, global = true)]
|
||||
argv: Vec<String>,
|
||||
}
|
||||
|
||||
fn main() {
|
||||
Builder::new()
|
||||
.format(|buf, record| writeln!(buf, "{}: {}", record.level(), record.args()))
|
||||
.format(|buf, record| {
|
||||
writeln!(
|
||||
buf,
|
||||
"{} {}: {}",
|
||||
record.target(),
|
||||
record.level(),
|
||||
record.args()
|
||||
)
|
||||
})
|
||||
.parse_default_env()
|
||||
.init();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user