Sign in
fuchsia
/
third_party
/
rust
/
a7a6dedfe661a6d9d181afeb0fbaa894fcb7362b
/
.
/
src
/
test
/
ui
/
issues
/
issue-52213.rs
blob: c4ce4946b2e28f6f7f4c6f80e0e49034712bd06e [
file
] [
log
] [
blame
]
fn
transmute_lifetime
<
'a, '
b
,
T
>(
t
:
&
'a (T,)) -> &'
b T
{
match
(&
t
,)
{
//~ ERROR cannot infer an appropriate lifetime
((
u
,),)
=>
u
,
}
}
fn
main
()
{
let
x
=
{
let
y
=
Box
::
new
((
42
,));
transmute_lifetime
(&
y
)
};
println
!(
"{}"
,
x
);
}