Skip to content

Commit 5f56956

Browse files
committed
implement Sync for mpsc::Sender
1 parent 7820972 commit 5f56956

File tree

1 file changed

+2
-2
lines changed
  • library/std/src/sync/mpsc

1 file changed

+2
-2
lines changed

library/std/src/sync/mpsc/mod.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -347,8 +347,8 @@ pub struct Sender<T> {
347347
#[stable(feature = "rust1", since = "1.0.0")]
348348
unsafe impl<T: Send> Send for Sender<T> {}
349349

350-
#[stable(feature = "rust1", since = "1.0.0")]
351-
impl<T> !Sync for Sender<T> {}
350+
#[stable(feature = "mpsc_sender_sync", since = "CURRENT_RUSTC_VERSION")]
351+
unsafe impl<T: Send> Sync for Sender<T> {}
352352

353353
/// The sending-half of Rust's synchronous [`sync_channel`] type.
354354
///

0 commit comments

Comments
 (0)