2024-11-29 04:28:02 +01:00
|
|
|
#![expect(incomplete_features)]
|
2023-06-28 15:34:10 +00:00
|
|
|
#![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() {}
|