Sign in
fuchsia
/
third_party
/
rust
/
08351004125c4d49aa757f2c3ec2340f7469ea91
/
.
/
src
/
test
/
ui
/
borrowck
/
borrowck-issue-2657-1.rs
blob: c38293740edaa4c6b385c9c30023c8089149cd32 [
file
] [
log
] [
blame
]
#![
feature
(
box_syntax
)]
fn
main
()
{
let
x
:
Option
<
Box
<
_
>>
=
Some
(
box
1
);
match
x
{
Some
(
ref
_y
)
=>
{
let
_a
=
x
;
//~ ERROR cannot move
_y
.
use_ref
();
}
_
=>
{}
}
}
trait
Fake
{
fn
use_mut
(&
mut
self
)
{
}
fn
use_ref
(&
self
)
{
}
}
impl
<
T
>
Fake
for
T
{
}