Only print last evaluated result
This commit is contained in:
parent
e0f5f01e69
commit
9dd8f90e3c
@ -124,8 +124,8 @@ fn run_noninteractive<'a, T: ProgrammingLanguage>(filename: &str, _language: &T,
|
|||||||
evaluator.set_option("trace_evaluation", true);
|
evaluator.set_option("trace_evaluation", true);
|
||||||
}
|
}
|
||||||
let results = T::evaluate(ast, &mut evaluator);
|
let results = T::evaluate(ast, &mut evaluator);
|
||||||
for result in results.iter() {
|
if let Some(r) = results.iter().last() {
|
||||||
println!("{}", result);
|
println!("{}", r);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user