diff options
Diffstat (limited to 'tests/ui/pin_project/remove-attr-from-field.rs')
-rw-r--r-- | tests/ui/pin_project/remove-attr-from-field.rs | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/ui/pin_project/remove-attr-from-field.rs b/tests/ui/pin_project/remove-attr-from-field.rs index 1ecd56f..bec8302 100644 --- a/tests/ui/pin_project/remove-attr-from-field.rs +++ b/tests/ui/pin_project/remove-attr-from-field.rs @@ -1,4 +1,4 @@ -use auxiliary_macros::remove_attr; +use auxiliary_macro::remove_attr; use pin_project::pin_project; use std::{marker::PhantomPinned, pin::Pin}; @@ -8,25 +8,25 @@ fn is_unpin<T: Unpin>() {} #[remove_attr(field_all)] struct A { #[pin] - field: PhantomPinned, + f: PhantomPinned, } #[remove_attr(field_all)] #[pin_project] struct B { #[pin] - field: PhantomPinned, + f: PhantomPinned, } fn main() { is_unpin::<A>(); is_unpin::<B>(); - let mut x = A { field: PhantomPinned }; + let mut x = A { f: PhantomPinned }; let x = Pin::new(&mut x).project(); - let _: Pin<&mut PhantomPinned> = x.field; //~ ERROR E0308 + let _: Pin<&mut PhantomPinned> = x.f; //~ ERROR E0308 - let mut x = B { field: PhantomPinned }; + let mut x = B { f: PhantomPinned }; let x = Pin::new(&mut x).project(); - let _: Pin<&mut PhantomPinned> = x.field; //~ ERROR E0308 + let _: Pin<&mut PhantomPinned> = x.f; //~ ERROR E0308 } |