diff --git a/src/marker.rs b/src/marker.rs index e648dd2..e8874bd 100644 --- a/src/marker.rs +++ b/src/marker.rs @@ -12,7 +12,10 @@ mod value { pub(crate) use core::marker::PhantomData as Marker; } -pub(crate) struct ProcMacroAutoTraits(Rc<()>); +pub(crate) struct ProcMacroAutoTraits( + #[allow(dead_code)] // https://github.com/rust-lang/rust/issues/119645 + Rc<()>, +); impl UnwindSafe for ProcMacroAutoTraits {} impl RefUnwindSafe for ProcMacroAutoTraits {} diff --git a/tests/ui/test-not-send.stderr b/tests/ui/test-not-send.stderr index ea84607..abaab5a 100644 --- a/tests/ui/test-not-send.stderr +++ b/tests/ui/test-not-send.stderr @@ -31,7 +31,7 @@ error[E0277]: `Rc<()>` cannot be sent between threads safely note: required because it appears within the type `proc_macro2::marker::ProcMacroAutoTraits` --> $WORKSPACE/src/marker.rs | - | pub(crate) struct ProcMacroAutoTraits(Rc<()>); + | pub(crate) struct ProcMacroAutoTraits( | ^^^^^^^^^^^^^^^^^^^ note: required because it appears within the type `PhantomData` --> $RUST/core/src/marker.rs