Sign in
fuchsia
/
third_party
/
rust
/
15f159addefd8fea7564ba7617c8af78582b7816
/
.
/
src
/
test
/
ui
/
span
/
regions-close-over-borrowed-ref-in-obj.rs
blob: e34f84683bbc7777b994f55dc7f737c7e87dfeb1 [
file
] [
log
] [
blame
]
#![
feature
(
box_syntax
)]
fn
id
<
T
>(
x
:
T
)
->
T
{
x
}
trait
Foo
{
}
impl
<
'a> Foo for &'
a isize
{
}
fn
main
()
{
let
blah
;
{
let
ss
:
&
isize
=
&
id
(
1
);
//~^ ERROR temporary value dropped while borrowed
blah
=
box ss
as
Box
<
dyn
Foo
>;
}
}