File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change 59
59
TokenStream : Send + Sync ,
60
60
{ }
61
61
62
+ // These are safe since we ensure that they hold for all fields in the `_dummy` function.
63
+ //
64
+ // These impls are only here because the compiler takes forever to compute the Send and Sync
65
+ // bounds without them.
66
+ // FIXME: Remove these impls when the compiler can compute the bounds quickly again.
67
+ // See https://github.com/rust-lang/rust/issues/60846
68
+ #[ cfg( all( bootstrap, parallel_compiler) ) ]
69
+ unsafe impl Send for TokenTree { }
70
+ #[ cfg( all( bootstrap, parallel_compiler) ) ]
71
+ unsafe impl Sync for TokenTree { }
72
+
62
73
impl TokenTree {
63
74
/// Use this token tree as a matcher to parse given tts.
64
75
pub fn parse ( cx : & base:: ExtCtxt < ' _ > , mtch : & [ quoted:: TokenTree ] , tts : TokenStream )
You can’t perform that action at this time.
0 commit comments