File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed
src/librustc_data_structures Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -175,7 +175,11 @@ cfg_if! {
175
175
where A : FnOnce ( ) -> RA ,
176
176
B : FnOnce ( ) -> RB
177
177
{
178
- ( oper_a( ) , oper_b( ) )
178
+ let panic = Lock :: new( None ) ;
179
+ let a = catch( & panic, oper_a) ;
180
+ let b = catch( & panic, oper_b) ;
181
+ resume( panic) ;
182
+ ( a. unwrap( ) , b. unwrap( ) )
179
183
}
180
184
181
185
pub struct SerialScope ;
@@ -204,8 +208,8 @@ cfg_if! {
204
208
$crate :: sync:: catch( & panic, || $blocks) ;
205
209
) *
206
210
$crate :: sync:: resume( panic) ;
211
+ }
207
212
}
208
- }
209
213
210
214
use std:: iter:: { Iterator , IntoIterator , FromIterator } ;
211
215
@@ -220,7 +224,7 @@ cfg_if! {
220
224
catch( & panic, || for_each( i) ) ;
221
225
} ) ;
222
226
resume( panic) ;
223
- }
227
+ }
224
228
225
229
pub fn par_map<T : IntoIterator , R , C : FromIterator <R >>(
226
230
t: T ,
You can’t perform that action at this time.
0 commit comments