Sign in
android
/
toolchain
/
rustc
/
refs/heads/main
/
.
/
tests
/
ui
/
explicit-tail-calls
/
ctfe-arg-bad-borrow.rs
blob: 5a105ee4eb59dec0d4eb289a1727b2c7fd2e53df [
file
] [
log
] [
blame
] [
edit
]
#![
allow
(
incomplete_features
)]
#![
feature
(
explicit_tail_calls
)]
pub
const
fn
test
(
_
:
&
Type
)
{
const
fn
takes_borrow
(
_
:
&
Type
)
{}
let
local
=
Type
;
become takes_borrow
(&
local
);
//~^ error: `local` does not live long enough
}
struct
Type
;
fn
main
()
{}