From 6877244b2859bdf4b687b1332bc14b0d418e8269 Mon Sep 17 00:00:00 2001 From: Taiki Endo Date: Sun, 6 Sep 2020 22:55:24 +0900 Subject: [PATCH] Use collect::>() directly in ShardedLock::new() --- crossbeam-utils/src/sync/sharded_lock.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/crossbeam-utils/src/sync/sharded_lock.rs b/crossbeam-utils/src/sync/sharded_lock.rs index e420a811b..60793940b 100644 --- a/crossbeam-utils/src/sync/sharded_lock.rs +++ b/crossbeam-utils/src/sync/sharded_lock.rs @@ -106,8 +106,7 @@ impl ShardedLock { write_guard: UnsafeCell::new(None), }) }) - .collect::>() - .into_boxed_slice(), + .collect::>(), value: UnsafeCell::new(value), } }