rust/tests/ui/feature-gates/feature-gate-box_syntax.rs
2023-01-11 09:32:08 +00:00

7 lines
198 B
Rust

// Test that the use of the box syntax is gated by `box_syntax` feature gate.
fn main() {
let x = box 3;
//~^ ERROR box expression syntax is experimental; you can call `Box::new` instead
}