File tree Expand file tree Collapse file tree 4 files changed +2
-8
lines changed Expand file tree Collapse file tree 4 files changed +2
-8
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ use std::marker::PhantomData;
22use std:: ops:: Deref ;
33use std:: sync:: atomic:: { AtomicUsize , Ordering } ;
44use std:: sync:: { Arc , Condvar , Mutex } ;
5- use std:: usize;
65
76use crate :: registry:: { Registry , WorkerThread } ;
87
Original file line number Diff line number Diff line change @@ -18,7 +18,6 @@ use std::ptr;
1818use std:: sync:: atomic:: { AtomicUsize , Ordering } ;
1919use std:: sync:: { Arc , Mutex , Once } ;
2020use std:: thread;
21- use std:: usize;
2221
2322/// Thread builder used for customization via
2423/// [`ThreadPoolBuilder::spawn_handler`](struct.ThreadPoolBuilder.html#method.spawn_handler).
@@ -599,10 +598,7 @@ impl Registry {
599598 pub ( super ) fn increment_terminate_count ( & self ) {
600599 let previous = self . terminate_count . fetch_add ( 1 , Ordering :: AcqRel ) ;
601600 debug_assert ! ( previous != 0 , "registry ref count incremented from zero" ) ;
602- assert ! (
603- previous != std:: usize :: MAX ,
604- "overflow in registry ref count"
605- ) ;
601+ assert ! ( previous != usize :: MAX , "overflow in registry ref count" ) ;
606602 }
607603
608604 /// Signals that the thread-pool which owns this registry has been
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ pub(super) struct Counters {
2727pub ( super ) struct JobsEventCounter ( usize ) ;
2828
2929impl JobsEventCounter {
30- pub ( super ) const DUMMY : JobsEventCounter = JobsEventCounter ( std :: usize:: MAX ) ;
30+ pub ( super ) const DUMMY : JobsEventCounter = JobsEventCounter ( usize:: MAX ) ;
3131
3232 #[ inline]
3333 pub ( super ) fn as_usize ( self ) -> usize {
Original file line number Diff line number Diff line change @@ -8,7 +8,6 @@ use crossbeam_utils::CachePadded;
88use std:: sync:: atomic:: Ordering ;
99use std:: sync:: { Condvar , Mutex } ;
1010use std:: thread;
11- use std:: usize;
1211
1312mod counters;
1413pub ( crate ) use self :: counters:: THREADS_MAX ;
You can’t perform that action at this time.
0 commit comments