@@ -402,14 +402,15 @@ pub struct CompileController<'a> {
402
402
403
403
/// Allows overriding default rustc query providers,
404
404
/// after `default_provide` has installed them.
405
- pub provide : Box < dyn Fn ( & mut ty:: query:: Providers ) + ' a > ,
405
+ pub provide : Box < dyn Fn ( & mut ty:: query:: Providers ) + ' a + sync :: Send > ,
406
406
/// Same as `provide`, but only for non-local crates,
407
407
/// applied after `default_provide_extern`.
408
- pub provide_extern : Box < dyn Fn ( & mut ty:: query:: Providers ) + ' a > ,
408
+ pub provide_extern : Box < dyn Fn ( & mut ty:: query:: Providers ) + ' a + sync :: Send > ,
409
409
}
410
410
411
411
impl < ' a > CompileController < ' a > {
412
412
pub fn basic ( ) -> CompileController < ' a > {
413
+ sync:: assert_send :: < Self > ( ) ;
413
414
CompileController {
414
415
after_parse : PhaseController :: basic ( ) ,
415
416
after_expand : PhaseController :: basic ( ) ,
@@ -499,7 +500,7 @@ pub struct PhaseController<'a> {
499
500
// If true then the compiler will try to run the callback even if the phase
500
501
// ends with an error. Note that this is not always possible.
501
502
pub run_callback_on_error : bool ,
502
- pub callback : Box < dyn Fn ( & mut CompileState ) + ' a > ,
503
+ pub callback : Box < dyn Fn ( & mut CompileState ) + ' a + sync :: Send > ,
503
504
}
504
505
505
506
impl < ' a > PhaseController < ' a > {
0 commit comments