@@ -72,23 +72,14 @@ pub struct QueryJob<I> {
7272
7373impl < I > Clone for QueryJob < I > {
7474 fn clone ( & self ) -> Self {
75- Self {
76- id : self . id ,
77- span : self . span ,
78- parent : self . parent ,
79- latch : self . latch . clone ( ) ,
80- }
75+ Self { id : self . id , span : self . span , parent : self . parent , latch : self . latch . clone ( ) }
8176 }
8277}
8378
8479impl < I > QueryJob < I > {
8580 /// Creates a new query job.
8681 #[ inline]
87- pub fn new (
88- id : QueryJobId ,
89- span : Span ,
90- parent : Option < QueryInclusion > ,
91- ) -> Self {
82+ pub fn new ( id : QueryJobId , span : Span , parent : Option < QueryInclusion > ) -> Self {
9283 QueryJob { id, span, parent, latch : Weak :: new ( ) }
9384 }
9485
@@ -211,12 +202,8 @@ impl<I> QueryLatch<I> {
211202 query : Option < QueryInclusion > ,
212203 span : Span ,
213204 ) -> Result < ( ) , CycleError < I > > {
214- let waiter = Arc :: new ( QueryWaiter {
215- query,
216- span,
217- cycle : Mutex :: new ( None ) ,
218- condvar : Condvar :: new ( ) ,
219- } ) ;
205+ let waiter =
206+ Arc :: new ( QueryWaiter { query, span, cycle : Mutex :: new ( None ) , condvar : Condvar :: new ( ) } ) ;
220207 self . wait_on_inner ( qcx, & waiter) ;
221208 // FIXME: Get rid of this lock. We have ownership of the QueryWaiter
222209 // although another thread may still have a Arc reference so we cannot
0 commit comments