Move optimization_level into Options.

This commit is contained in:
Stephen Chung
2022-03-29 08:26:42 +08:00
parent 1b6de25007
commit 56f6b181db
6 changed files with 24 additions and 17 deletions

View File

@@ -67,7 +67,7 @@ impl Engine {
let ast = self.compile_with_scope_and_optimization_level(
scope,
&[script],
self.optimization_level,
self.options.optimization_level,
)?;
self.eval_ast_with_scope(scope, &ast)
}