style: Fix Servo build, and rustfmt recent changes.

This commit is contained in:
Emilio Cobos Álvarez 2019-09-12 22:44:31 +02:00
parent 9eaadc6860
commit cd3b0c23fa
No known key found for this signature in database
GPG key ID: E1152D0994E4BF8A
15 changed files with 90 additions and 60 deletions

View file

@ -1497,11 +1497,10 @@ impl LayoutThread {
// Create a layout context for use throughout the following passes.
let mut layout_context = self.build_layout_context(guards.clone(), true, &map);
let pool;
let (thread_pool, num_threads) = if self.parallel_flag {
(
STYLE_THREAD_POOL.style_thread_pool.as_ref(),
STYLE_THREAD_POOL.num_threads,
)
pool = STYLE_THREAD_POOL.pool();
(pool.as_ref(), STYLE_THREAD_POOL.num_threads)
} else {
(None, 1)
};
@ -1859,8 +1858,10 @@ impl LayoutThread {
|| {
let profiler_metadata = self.profiler_metadata();
let pool;
let thread_pool = if self.parallel_flag {
STYLE_THREAD_POOL.style_thread_pool.as_ref()
pool = STYLE_THREAD_POOL.pool();
pool.as_ref()
} else {
None
};