Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use optimization level 2 by default in lune cli #268

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion crates/lune/src/rt/runtime.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,10 @@ use std::{
},
};

use mlua::prelude::*;
use mlua::{
prelude::*,
Compiler,
};
use mlua_luau_scheduler::{Functions, Scheduler};
use self_cell::self_cell;

Expand All @@ -30,6 +33,10 @@ impl RuntimeInner {
fn create() -> LuaResult<Self> {
let lua = Rc::new(Lua::new());

let compiler = Compiler::new()
.set_optimization_level(2);

lua.set_compiler(compiler);
lua.set_app_data(Rc::downgrade(&lua));
lua.set_app_data(Vec::<String>::new());

Expand Down
Loading