mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-23 23:34:48 +00:00
16 lines
340 B
Rust
16 lines
340 B
Rust
//@ revisions: constant array
|
|
#![allow(incomplete_features)]
|
|
#![feature(explicit_tail_calls)]
|
|
|
|
#[cfg(constant)]
|
|
const _: () = {
|
|
become f(); //[constant]~ error: become statement outside of function body
|
|
};
|
|
|
|
#[cfg(array)]
|
|
struct Bad([(); become f()]); //[array]~ error: become statement outside of function body
|
|
|
|
fn f() {}
|
|
|
|
fn main() {}
|