1
Fork 0

Clarify run_in_thread_pool_with_globals.

- Make the structure of the two variants more similar.
- Add some comments.
- Move various conditional `use` items inside the function that uses
  them.
- Inline some closures.
This commit is contained in:
Nicholas Nethercote 2022-10-10 10:50:14 +11:00
parent 2efc90e738
commit cf13d9143d
2 changed files with 46 additions and 44 deletions

View file

@ -190,6 +190,7 @@ impl<'a, 'b> RunCompiler<'a, 'b> {
run_compiler(self.at_args, self.callbacks, self.file_loader, self.make_codegen_backend)
}
}
fn run_compiler(
at_args: &[String],
callbacks: &mut (dyn Callbacks + Send),