// SPDX-License-Identifier: Apache-2.0 OR MIT use pin_project_lite::pin_project; // The same implementation. pin_project! { //~ ERROR E0119 struct Foo { #[pin] future: T, field: U, } } // conflicting implementations impl Unpin for Foo where T: Unpin {} // Conditional Unpin impl // The implementation that under different conditions. pin_project! { //~ ERROR E0119 struct Bar { #[pin] future: T, field: U, } } // conflicting implementations impl Unpin for Bar {} // Non-conditional Unpin impl pin_project! { //~ ERROR E0119 struct Baz { #[pin] future: T, field: U, } } // conflicting implementations impl Unpin for Baz {} // Conditional Unpin impl pin_project! { //~ ERROR E0119 #[project(!Unpin)] struct Qux { #[pin] future: T, field: U, } } // conflicting implementations impl Unpin for Qux {} // Non-conditional Unpin impl pin_project! { //~ ERROR E0119 #[project(!Unpin)] struct Fred { #[pin] future: T, field: U, } } // conflicting implementations impl Unpin for Fred {} // Conditional Unpin impl fn main() {}