diff --git a/compiler/rustc_ast/src/lib.rs b/compiler/rustc_ast/src/lib.rs index 922e86e386b..502bd69e6a9 100644 --- a/compiler/rustc_ast/src/lib.rs +++ b/compiler/rustc_ast/src/lib.rs @@ -8,7 +8,6 @@ html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/", test(attr(deny(warnings))) )] -#![feature(box_syntax)] #![feature(box_patterns)] #![cfg_attr(bootstrap, feature(const_fn_transmute))] #![feature(crate_visibility_modifier)] diff --git a/compiler/rustc_ast/src/ptr.rs b/compiler/rustc_ast/src/ptr.rs index e4a3cccb7ea..9fe87a0a637 100644 --- a/compiler/rustc_ast/src/ptr.rs +++ b/compiler/rustc_ast/src/ptr.rs @@ -37,7 +37,7 @@ pub struct P { /// Construct a `P` from a `T` value. #[allow(non_snake_case)] pub fn P(value: T) -> P { - P { ptr: box value } + P { ptr: Box::new(value) } } impl P {