Sign in
fuchsia
/
third_party
/
rust
/
7de9402b77ded0d8ec9e1c554521b2121449ef2b
/
.
/
src
/
test
/
ui
/
issues
/
issue-2748-b.rs
blob: 8df735ac88ea6e374b292eeca7b763bb4007f5a2 [
file
] [
log
] [
blame
]
// run-pass
fn
thing
<
'r>(x: &'
r
[
isize
])
->
&
'
r
[
isize
]
{
x
}
pub
fn
main
()
{
let
x
=
&[
1
,
2
,
3
];
let
y
=
x
;
let
z
=
thing
(
x
);
assert_eq
!(
z
[
2
],
x
[
2
]);
assert_eq
!(
z
[
1
],
y
[
1
]);
}