2021-03-26 08:39:04 -05:00
|
|
|
#![deny(large_assignments)]
|
2021-03-26 11:28:52 -05:00
|
|
|
#![feature(large_assignments)]
|
2021-06-18 19:00:00 -05:00
|
|
|
#![cfg_attr(attribute, move_size_limit = "1000")]
|
2021-03-26 08:39:04 -05:00
|
|
|
// build-fail
|
2021-03-29 09:22:01 -05:00
|
|
|
// only-x86_64
|
2021-06-18 19:00:00 -05:00
|
|
|
// revisions: attribute option
|
|
|
|
// [option]compile-flags: -Zmove-size-limit=1000
|
2021-03-26 08:39:04 -05:00
|
|
|
|
|
|
|
// edition:2018
|
2022-04-24 16:34:24 -05:00
|
|
|
// compile-flags: -Zmir-opt-level=0
|
2021-03-26 08:39:04 -05:00
|
|
|
|
|
|
|
fn main() {
|
|
|
|
let x = async { //~ ERROR large_assignments
|
|
|
|
let y = [0; 9999];
|
|
|
|
dbg!(y);
|
|
|
|
thing(&y).await;
|
|
|
|
dbg!(y);
|
|
|
|
};
|
|
|
|
let z = (x, 42); //~ ERROR large_assignments
|
|
|
|
//~^ ERROR large_assignments
|
|
|
|
let a = z.0; //~ ERROR large_assignments
|
|
|
|
let b = z.1;
|
|
|
|
}
|
|
|
|
|
|
|
|
async fn thing(y: &[u8]) {
|
|
|
|
dbg!(y);
|
2021-03-26 11:33:14 -05:00
|
|
|
}
|