Sign in
fuchsia
/
third_party
/
rust
/
08351004125c4d49aa757f2c3ec2340f7469ea91
/
.
/
src
/
test
/
ui
/
borrowck
/
two-phase-method-receivers.rs
blob: 6838f6c7efd5d24f36df3baba576f0cffebe866c [
file
] [
log
] [
blame
]
// compile-flags: -Z borrowck=mir
// run-pass
struct
Foo
<
'
a
>
{
x
:
&
'
a i32
}
impl
<
'a> Foo<'
a
>
{
fn
method
(&
mut
self
,
_
:
&
i32
)
{
}
}
fn
main
()
{
let
a
=
&
mut
Foo
{
x
:
&
22
};
Foo
::
method
(
a
,
a
.
x
);
}