aboutsummaryrefslogtreecommitdiff
path: root/tests/ui/pin_project
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/pin_project')
-rw-r--r--tests/ui/pin_project/add-attr-to-struct.stderr4
-rw-r--r--tests/ui/pin_project/add-pinned-field.stderr19
-rw-r--r--tests/ui/pin_project/conflict-drop.stderr2
-rw-r--r--tests/ui/pin_project/conflict-unpin.stderr6
-rw-r--r--tests/ui/pin_project/impl-unsafe-unpin.stderr6
-rw-r--r--tests/ui/pin_project/overlapping_unpin_struct.stderr9
-rw-r--r--tests/ui/pin_project/packed-name-value.stderr12
-rw-r--r--tests/ui/pin_project/packed_sneaky-2.stderr2
-rw-r--r--tests/ui/pin_project/packed_sneaky-3.stderr6
-rw-r--r--tests/ui/pin_project/project_replace_unsized.stderr60
-rw-r--r--tests/ui/pin_project/project_replace_unsized_fn_params.stderr60
-rw-r--r--tests/ui/pin_project/remove-attr-from-struct.stderr46
12 files changed, 141 insertions, 91 deletions
diff --git a/tests/ui/pin_project/add-attr-to-struct.stderr b/tests/ui/pin_project/add-attr-to-struct.stderr
index f3ee9e4..b28559b 100644
--- a/tests/ui/pin_project/add-attr-to-struct.stderr
+++ b/tests/ui/pin_project/add-attr-to-struct.stderr
@@ -4,7 +4,7 @@ error: duplicate #[pin] attribute
7 | #[add_pin_attr(struct)] //~ ERROR duplicate #[pin] attribute
| ^^^^^^^^^^^^^^^^^^^^^^^
|
- = note: this error originates in an attribute macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the attribute macro `add_pin_attr` (in Nightly builds, run with -Z macro-backtrace for more info)
error: #[pin] attribute may only be used on fields of structs or variants
--> $DIR/add-attr-to-struct.rs:13:1
@@ -12,4 +12,4 @@ error: #[pin] attribute may only be used on fields of structs or variants
13 | #[add_pin_attr(struct)] //~ ERROR #[pin] attribute may only be used on fields of structs or variants
| ^^^^^^^^^^^^^^^^^^^^^^^
|
- = note: this error originates in an attribute macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the attribute macro `add_pin_attr` (in Nightly builds, run with -Z macro-backtrace for more info)
diff --git a/tests/ui/pin_project/add-pinned-field.stderr b/tests/ui/pin_project/add-pinned-field.stderr
index a391f3b..bdeafb8 100644
--- a/tests/ui/pin_project/add-pinned-field.stderr
+++ b/tests/ui/pin_project/add-pinned-field.stderr
@@ -13,7 +13,15 @@ note: required because it appears within the type `__Foo<'_>`
|
8 | struct Foo {
| ^^^
- = note: required because of the requirements on the impl of `Unpin` for `Foo`
+note: required because of the requirements on the impl of `Unpin` for `Foo`
+ --> $DIR/add-pinned-field.rs:6:1
+ |
+6 | #[pin_project]
+ | ^^^^^^^^^^^^^^
+7 | #[add_pinned_field]
+8 | struct Foo {
+ | ^^^
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
error[E0277]: `PhantomPinned` cannot be unpinned
--> $DIR/add-pinned-field.rs:22:5
@@ -30,4 +38,11 @@ note: required because it appears within the type `__Bar<'_>`
|
15 | struct Bar {
| ^^^
- = note: required because of the requirements on the impl of `Unpin` for `Bar`
+note: required because of the requirements on the impl of `Unpin` for `Bar`
+ --> $DIR/add-pinned-field.rs:14:1
+ |
+14 | #[pin_project]
+ | ^^^^^^^^^^^^^^
+15 | struct Bar {
+ | ^^^
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
diff --git a/tests/ui/pin_project/conflict-drop.stderr b/tests/ui/pin_project/conflict-drop.stderr
index ae51456..25b0e00 100644
--- a/tests/ui/pin_project/conflict-drop.stderr
+++ b/tests/ui/pin_project/conflict-drop.stderr
@@ -7,7 +7,7 @@ error[E0119]: conflicting implementations of trait `_::FooMustNotImplDrop` for t
| first implementation here
| conflicting implementation for `Foo<_, _>`
|
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
error[E0119]: conflicting implementations of trait `std::ops::Drop` for type `Bar<_, _>`
--> $DIR/conflict-drop.rs:16:15
diff --git a/tests/ui/pin_project/conflict-unpin.stderr b/tests/ui/pin_project/conflict-unpin.stderr
index 0401140..5a16469 100644
--- a/tests/ui/pin_project/conflict-unpin.stderr
+++ b/tests/ui/pin_project/conflict-unpin.stderr
@@ -7,7 +7,7 @@ error[E0119]: conflicting implementations of trait `std::marker::Unpin` for type
13 | impl<T, U> Unpin for Foo<T, U> where T: Unpin {} // Conditional Unpin impl
| --------------------------------------------- first implementation here
|
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
error[E0119]: conflicting implementations of trait `std::marker::Unpin` for type `Bar<_, _>`
--> $DIR/conflict-unpin.rs:17:1
@@ -18,7 +18,7 @@ error[E0119]: conflicting implementations of trait `std::marker::Unpin` for type
25 | impl<T, U> Unpin for Bar<T, U> {} // Non-conditional Unpin impl
| ------------------------------ first implementation here
|
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
error[E0119]: conflicting implementations of trait `std::marker::Unpin` for type `Baz<_, _>`
--> $DIR/conflict-unpin.rs:27:1
@@ -29,4 +29,4 @@ error[E0119]: conflicting implementations of trait `std::marker::Unpin` for type
35 | impl<T: Unpin, U: Unpin> Unpin for Baz<T, U> {} // Conditional Unpin impl
| -------------------------------------------- first implementation here
|
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
diff --git a/tests/ui/pin_project/impl-unsafe-unpin.stderr b/tests/ui/pin_project/impl-unsafe-unpin.stderr
index 078baee..e97d31b 100644
--- a/tests/ui/pin_project/impl-unsafe-unpin.stderr
+++ b/tests/ui/pin_project/impl-unsafe-unpin.stderr
@@ -7,7 +7,7 @@ error[E0119]: conflicting implementations of trait `pin_project::UnsafeUnpin` fo
10 | unsafe impl<T, U> UnsafeUnpin for Foo<T, U> where T: Unpin {}
| ---------------------------------------------------------- first implementation here
|
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
error[E0119]: conflicting implementations of trait `pin_project::UnsafeUnpin` for type `Bar<_, _>`
--> $DIR/impl-unsafe-unpin.rs:12:1
@@ -18,7 +18,7 @@ error[E0119]: conflicting implementations of trait `pin_project::UnsafeUnpin` fo
19 | unsafe impl<T, U> UnsafeUnpin for Bar<T, U> {}
| ------------------------------------------- first implementation here
|
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
error[E0119]: conflicting implementations of trait `pin_project::UnsafeUnpin` for type `Baz<_, _>`
--> $DIR/impl-unsafe-unpin.rs:21:1
@@ -29,4 +29,4 @@ error[E0119]: conflicting implementations of trait `pin_project::UnsafeUnpin` fo
28 | unsafe impl<T: Unpin, U: Unpin> UnsafeUnpin for Baz<T, U> {}
| --------------------------------------------------------- first implementation here
|
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
diff --git a/tests/ui/pin_project/overlapping_unpin_struct.stderr b/tests/ui/pin_project/overlapping_unpin_struct.stderr
index f49c736..bb33944 100644
--- a/tests/ui/pin_project/overlapping_unpin_struct.stderr
+++ b/tests/ui/pin_project/overlapping_unpin_struct.stderr
@@ -13,4 +13,11 @@ note: required because it appears within the type `_::__S<'_, PhantomPinned>`
|
6 | struct S<T> {
| ^
- = note: required because of the requirements on the impl of `Unpin` for `S<PhantomPinned>`
+note: required because of the requirements on the impl of `Unpin` for `S<PhantomPinned>`
+ --> $DIR/overlapping_unpin_struct.rs:5:1
+ |
+5 | #[pin_project]
+ | ^^^^^^^^^^^^^^
+6 | struct S<T> {
+ | ^^^^
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
diff --git a/tests/ui/pin_project/packed-name-value.stderr b/tests/ui/pin_project/packed-name-value.stderr
index 51b82dd..18137d4 100644
--- a/tests/ui/pin_project/packed-name-value.stderr
+++ b/tests/ui/pin_project/packed-name-value.stderr
@@ -9,3 +9,15 @@ error: #[repr(packed)] attribute should not be name-value pair
|
21 | #[repr(packed = "")] //~ ERROR attribute should not be name-value pair
| ^^^^^^^^^^^
+
+error[E0693]: incorrect `repr(packed)` attribute format
+ --> $DIR/packed-name-value.rs:16:8
+ |
+16 | #[repr(packed = "")] //~ ERROR attribute should not be name-value pair
+ | ^^^^^^^^^^^ help: use parentheses instead: `packed()`
+
+error[E0693]: incorrect `repr(packed)` attribute format
+ --> $DIR/packed-name-value.rs:21:8
+ |
+21 | #[repr(packed = "")] //~ ERROR attribute should not be name-value pair
+ | ^^^^^^^^^^^ help: use parentheses instead: `packed()`
diff --git a/tests/ui/pin_project/packed_sneaky-2.stderr b/tests/ui/pin_project/packed_sneaky-2.stderr
index 51987a2..04d072a 100644
--- a/tests/ui/pin_project/packed_sneaky-2.stderr
+++ b/tests/ui/pin_project/packed_sneaky-2.stderr
@@ -10,4 +10,4 @@ error: #[pin_project] attribute may not be used on #[repr(packed)] types
10 | | }
| |_^
|
- = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the macro `hidden_repr_macro` (in Nightly builds, run with -Z macro-backtrace for more info)
diff --git a/tests/ui/pin_project/packed_sneaky-3.stderr b/tests/ui/pin_project/packed_sneaky-3.stderr
index b953e9f..1a5a3ec 100644
--- a/tests/ui/pin_project/packed_sneaky-3.stderr
+++ b/tests/ui/pin_project/packed_sneaky-3.stderr
@@ -4,7 +4,7 @@ error: expected item after attributes
4 | hidden_repr_macro! {} //~ ERROR expected item after attributes
| ^^^^^^^^^^^^^^^^^^^^^
|
- = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the macro `hidden_repr_macro` (in Nightly builds, run with -Z macro-backtrace for more info)
error: expected item after attributes
--> $DIR/packed_sneaky-3.rs:13:9
@@ -15,7 +15,7 @@ error: expected item after attributes
17 | hidden_repr_macro2! {}
| ---------------------- in this macro invocation
|
- = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the macro `hidden_repr_macro2` (in Nightly builds, run with -Z macro-backtrace for more info)
error: expected item after attributes
--> $DIR/packed_sneaky-3.rs:24:10
@@ -23,7 +23,7 @@ error: expected item after attributes
24 | #[derive(HiddenRepr)] //~ ERROR expected item after attributes
| ^^^^^^^^^^
|
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the derive macro `HiddenRepr` (in Nightly builds, run with -Z macro-backtrace for more info)
error: proc-macro derive produced unparseable tokens
--> $DIR/packed_sneaky-3.rs:24:10
diff --git a/tests/ui/pin_project/project_replace_unsized.stderr b/tests/ui/pin_project/project_replace_unsized.stderr
index 75a2666..d20d858 100644
--- a/tests/ui/pin_project/project_replace_unsized.stderr
+++ b/tests/ui/pin_project/project_replace_unsized.stderr
@@ -18,20 +18,24 @@ help: function arguments must have a statically known size, borrowed types alway
| ^
error[E0277]: the size for values of type `T` cannot be known at compilation time
- --> $DIR/project_replace_unsized.rs:3:1
- |
-3 | #[pin_project(project_replace)] //~ ERROR E0277
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
-4 | struct Struct<T: ?Sized> {
- | - this type parameter needs to be `std::marker::Sized`
- |
+ --> $DIR/project_replace_unsized.rs:3:1
+ |
+3 | #[pin_project(project_replace)] //~ ERROR E0277
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
+4 | struct Struct<T: ?Sized> {
+ | - this type parameter needs to be `std::marker::Sized`
+ |
note: required because it appears within the type `Struct<T>`
- --> $DIR/project_replace_unsized.rs:4:8
- |
-4 | struct Struct<T: ?Sized> {
- | ^^^^^^
- = note: required by `UnsafeOverwriteGuard`
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ --> $DIR/project_replace_unsized.rs:4:8
+ |
+4 | struct Struct<T: ?Sized> {
+ | ^^^^^^
+note: required by `UnsafeOverwriteGuard`
+ --> $DIR/lib.rs:269:5
+ |
+269 | pub struct UnsafeOverwriteGuard<T> {
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
error[E0277]: the size for values of type `T` cannot be known at compilation time
--> $DIR/project_replace_unsized.rs:5:5
@@ -61,20 +65,24 @@ help: function arguments must have a statically known size, borrowed types alway
| ^
error[E0277]: the size for values of type `T` cannot be known at compilation time
- --> $DIR/project_replace_unsized.rs:8:1
- |
-8 | #[pin_project(project_replace)] //~ ERROR E0277
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
-9 | struct TupleStruct<T: ?Sized>(T);
- | - this type parameter needs to be `std::marker::Sized`
- |
+ --> $DIR/project_replace_unsized.rs:8:1
+ |
+8 | #[pin_project(project_replace)] //~ ERROR E0277
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
+9 | struct TupleStruct<T: ?Sized>(T);
+ | - this type parameter needs to be `std::marker::Sized`
+ |
note: required because it appears within the type `TupleStruct<T>`
- --> $DIR/project_replace_unsized.rs:9:8
- |
-9 | struct TupleStruct<T: ?Sized>(T);
- | ^^^^^^^^^^^
- = note: required by `UnsafeOverwriteGuard`
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ --> $DIR/project_replace_unsized.rs:9:8
+ |
+9 | struct TupleStruct<T: ?Sized>(T);
+ | ^^^^^^^^^^^
+note: required by `UnsafeOverwriteGuard`
+ --> $DIR/lib.rs:269:5
+ |
+269 | pub struct UnsafeOverwriteGuard<T> {
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
error[E0277]: the size for values of type `T` cannot be known at compilation time
--> $DIR/project_replace_unsized.rs:9:8
diff --git a/tests/ui/pin_project/project_replace_unsized_fn_params.stderr b/tests/ui/pin_project/project_replace_unsized_fn_params.stderr
index f8cee98..8ac4ad7 100644
--- a/tests/ui/pin_project/project_replace_unsized_fn_params.stderr
+++ b/tests/ui/pin_project/project_replace_unsized_fn_params.stderr
@@ -15,20 +15,24 @@ note: required because it appears within the type `__StructProjectionOwned<T>`
= note: the return type of a function must have a statically known size
error[E0277]: the size for values of type `T` cannot be known at compilation time
- --> $DIR/project_replace_unsized_fn_params.rs:5:1
- |
-5 | #[pin_project(project_replace)] //~ ERROR E0277
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
-6 | struct Struct<T: ?Sized> {
- | - this type parameter needs to be `std::marker::Sized`
- |
+ --> $DIR/project_replace_unsized_fn_params.rs:5:1
+ |
+5 | #[pin_project(project_replace)] //~ ERROR E0277
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
+6 | struct Struct<T: ?Sized> {
+ | - this type parameter needs to be `std::marker::Sized`
+ |
note: required because it appears within the type `Struct<T>`
- --> $DIR/project_replace_unsized_fn_params.rs:6:8
- |
-6 | struct Struct<T: ?Sized> {
- | ^^^^^^
- = note: required by `UnsafeOverwriteGuard`
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ --> $DIR/project_replace_unsized_fn_params.rs:6:8
+ |
+6 | struct Struct<T: ?Sized> {
+ | ^^^^^^
+note: required by `UnsafeOverwriteGuard`
+ --> $DIR/lib.rs:269:5
+ |
+269 | pub struct UnsafeOverwriteGuard<T> {
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
error[E0277]: the size for values of type `T` cannot be known at compilation time
--> $DIR/project_replace_unsized_fn_params.rs:7:5
@@ -55,17 +59,21 @@ note: required because it appears within the type `__TupleStructProjectionOwned<
= note: the return type of a function must have a statically known size
error[E0277]: the size for values of type `T` cannot be known at compilation time
- --> $DIR/project_replace_unsized_fn_params.rs:10:1
- |
-10 | #[pin_project(project_replace)] //~ ERROR E0277
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
-11 | struct TupleStruct<T: ?Sized>(T);
- | - this type parameter needs to be `std::marker::Sized`
- |
+ --> $DIR/project_replace_unsized_fn_params.rs:10:1
+ |
+10 | #[pin_project(project_replace)] //~ ERROR E0277
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
+11 | struct TupleStruct<T: ?Sized>(T);
+ | - this type parameter needs to be `std::marker::Sized`
+ |
note: required because it appears within the type `TupleStruct<T>`
- --> $DIR/project_replace_unsized_fn_params.rs:11:8
- |
-11 | struct TupleStruct<T: ?Sized>(T);
- | ^^^^^^^^^^^
- = note: required by `UnsafeOverwriteGuard`
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ --> $DIR/project_replace_unsized_fn_params.rs:11:8
+ |
+11 | struct TupleStruct<T: ?Sized>(T);
+ | ^^^^^^^^^^^
+note: required by `UnsafeOverwriteGuard`
+ --> $DIR/lib.rs:269:5
+ |
+269 | pub struct UnsafeOverwriteGuard<T> {
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
diff --git a/tests/ui/pin_project/remove-attr-from-struct.stderr b/tests/ui/pin_project/remove-attr-from-struct.stderr
index 82fada5..57cf21d 100644
--- a/tests/ui/pin_project/remove-attr-from-struct.stderr
+++ b/tests/ui/pin_project/remove-attr-from-struct.stderr
@@ -4,7 +4,7 @@ error: #[pin_project] attribute has been removed
22 | #[pin_project] //~ ERROR has been removed
| ^^^^^^^^^^^^^^
|
- = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
+ = note: this error originates in the derive macro `::pin_project::__private::__PinProjectInternalDerive` (in Nightly builds, run with -Z macro-backtrace for more info)
error: cannot find attribute `pin` in this scope
--> $DIR/remove-attr-from-struct.rs:18:7
@@ -51,18 +51,18 @@ note: required because it appears within the type `B`
| ^
error[E0277]: `PhantomPinned` cannot be unpinned
- --> $DIR/remove-attr-from-struct.rs:40:13
- |
-40 | let _ = Pin::new(&mut x).project(); //~ ERROR E0277,E0599
- | ^^^^^^^^ within `A`, the trait `Unpin` is not implemented for `PhantomPinned`
- |
- = note: consider using `Box::pin`
+ --> $DIR/remove-attr-from-struct.rs:40:13
+ |
+40 | let _ = Pin::new(&mut x).project(); //~ ERROR E0277,E0599
+ | ^^^^^^^^ within `A`, the trait `Unpin` is not implemented for `PhantomPinned`
+ |
+ = note: consider using `Box::pin`
note: required because it appears within the type `A`
- --> $DIR/remove-attr-from-struct.rs:10:8
- |
-10 | struct A {
- | ^
- = note: required by `Pin::<P>::new`
+ --> $DIR/remove-attr-from-struct.rs:10:8
+ |
+10 | struct A {
+ | ^
+note: required by `Pin::<P>::new`
error[E0599]: no method named `project` found for struct `Pin<&mut A>` in the current scope
--> $DIR/remove-attr-from-struct.rs:40:30
@@ -71,18 +71,18 @@ error[E0599]: no method named `project` found for struct `Pin<&mut A>` in the cu
| ^^^^^^^ method not found in `Pin<&mut A>`
error[E0277]: `PhantomPinned` cannot be unpinned
- --> $DIR/remove-attr-from-struct.rs:43:13
- |
-43 | let _ = Pin::new(&mut x).project(); //~ ERROR E0277,E0599
- | ^^^^^^^^ within `B`, the trait `Unpin` is not implemented for `PhantomPinned`
- |
- = note: consider using `Box::pin`
+ --> $DIR/remove-attr-from-struct.rs:43:13
+ |
+43 | let _ = Pin::new(&mut x).project(); //~ ERROR E0277,E0599
+ | ^^^^^^^^ within `B`, the trait `Unpin` is not implemented for `PhantomPinned`
+ |
+ = note: consider using `Box::pin`
note: required because it appears within the type `B`
- --> $DIR/remove-attr-from-struct.rs:17:8
- |
-17 | struct B {
- | ^
- = note: required by `Pin::<P>::new`
+ --> $DIR/remove-attr-from-struct.rs:17:8
+ |
+17 | struct B {
+ | ^
+note: required by `Pin::<P>::new`
error[E0599]: no method named `project` found for struct `Pin<&mut B>` in the current scope
--> $DIR/remove-attr-from-struct.rs:43:30