aboutsummaryrefslogtreecommitdiff
path: root/tests/expand/unsafe_unpin/struct.expanded.rs
diff options
context:
space:
mode:
authorDavid LeGare <legare@google.com>2022-03-02 21:37:58 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2022-03-02 21:37:58 +0000
commit365fe11dc7cf47ae04d945af513246d19dfc00e8 (patch)
tree80c46c7f97eb0158db00b2c4710dd54073c36733 /tests/expand/unsafe_unpin/struct.expanded.rs
parent23cdec702c0235804c847247f16c7bc73f9d9fce (diff)
parentac81d17ea0cce1b865bbecae5677eeef7b1703e4 (diff)
downloadpin-project-365fe11dc7cf47ae04d945af513246d19dfc00e8.tar.gz
Update pin-project to 1.0.10 am: 8915193b0d am: ac81d17ea0
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/pin-project/+/2005953 Change-Id: I44e3dfdc6c005d46e30a740e77bb74955ccdfbd8
Diffstat (limited to 'tests/expand/unsafe_unpin/struct.expanded.rs')
-rw-r--r--tests/expand/unsafe_unpin/struct.expanded.rs21
1 files changed, 12 insertions, 9 deletions
diff --git a/tests/expand/unsafe_unpin/struct.expanded.rs b/tests/expand/unsafe_unpin/struct.expanded.rs
index 67ede39..a866ab3 100644
--- a/tests/expand/unsafe_unpin/struct.expanded.rs
+++ b/tests/expand/unsafe_unpin/struct.expanded.rs
@@ -14,10 +14,13 @@ struct Struct<T, U> {
#[allow(clippy::pattern_type_mismatch)]
#[allow(clippy::redundant_pub_crate)]
#[allow(clippy::type_repetition_in_bounds)]
+#[allow(unused_qualifications)]
#[allow(clippy::semicolon_if_nothing_returned)]
#[allow(clippy::use_self)]
#[allow(clippy::used_underscore_binding)]
const _: () = {
+ #[allow(unused_extern_crates)]
+ extern crate pin_project as _pin_project;
#[allow(dead_code)]
#[allow(clippy::mut_mut)]
struct __StructProjection<'pin, T, U>
@@ -38,24 +41,24 @@ const _: () = {
}
impl<T, U> Struct<T, U> {
fn project<'pin>(
- self: ::pin_project::__private::Pin<&'pin mut Self>,
+ self: _pin_project::__private::Pin<&'pin mut Self>,
) -> __StructProjection<'pin, T, U> {
unsafe {
let Self { pinned, unpinned } = self.get_unchecked_mut();
__StructProjection {
- pinned: ::pin_project::__private::Pin::new_unchecked(pinned),
+ pinned: _pin_project::__private::Pin::new_unchecked(pinned),
unpinned,
}
}
}
#[allow(clippy::missing_const_for_fn)]
fn project_ref<'pin>(
- self: ::pin_project::__private::Pin<&'pin Self>,
+ self: _pin_project::__private::Pin<&'pin Self>,
) -> __StructProjectionRef<'pin, T, U> {
unsafe {
let Self { pinned, unpinned } = self.get_ref();
__StructProjectionRef {
- pinned: ::pin_project::__private::Pin::new_unchecked(pinned),
+ pinned: _pin_project::__private::Pin::new_unchecked(pinned),
unpinned,
}
}
@@ -66,17 +69,17 @@ const _: () = {
let _ = &this.pinned;
let _ = &this.unpinned;
}
- impl<'pin, T, U> ::pin_project::__private::Unpin for Struct<T, U> where
- ::pin_project::__private::Wrapper<'pin, Self>: ::pin_project::UnsafeUnpin
+ impl<'pin, T, U> _pin_project::__private::Unpin for Struct<T, U> where
+ _pin_project::__private::Wrapper<'pin, Self>: _pin_project::UnsafeUnpin
{
}
trait StructMustNotImplDrop {}
#[allow(clippy::drop_bounds, drop_bounds)]
- impl<T: ::pin_project::__private::Drop> StructMustNotImplDrop for T {}
+ impl<T: _pin_project::__private::Drop> StructMustNotImplDrop for T {}
impl<T, U> StructMustNotImplDrop for Struct<T, U> {}
#[doc(hidden)]
- impl<T, U> ::pin_project::__private::PinnedDrop for Struct<T, U> {
- unsafe fn drop(self: ::pin_project::__private::Pin<&mut Self>) {}
+ impl<T, U> _pin_project::__private::PinnedDrop for Struct<T, U> {
+ unsafe fn drop(self: _pin_project::__private::Pin<&mut Self>) {}
}
};
unsafe impl<T: Unpin, U> UnsafeUnpin for Struct<T, U> {}