Sign in
android
/
toolchain
/
rustc
/
refs/heads/main
/
.
/
tests
/
ui
/
self
/
arbitrary_self_types_pin_lifetime_impl_trait-async.rs
blob: 43ad360e1967f0af9a0442188bdc639968478101 [
file
] [
log
] [
blame
] [
edit
]
//@ edition:2018
use
std
::
pin
::
Pin
;
struct
Foo
;
impl
Foo
{
async
fn
f
(
self
:
Pin
<&
Self
>)
->
impl
Clone
{
self
}
//~^ ERROR: captures lifetime that does not appear in bounds
}
fn
main
()
{
{
Pin
::
new
(&
Foo
).
f
()
};
}