提交 cdd8a5ad 编写于 作者: F Felix S. Klock II

Generalize all error messages with "experimental in alpha release" to

just say "experimental."
上级 dbe08286
......@@ -430,7 +430,7 @@ fn visit_expr(&mut self, e: &ast::Expr) {
ast::ExprBox(..) | ast::ExprUnary(ast::UnOp::UnUniq, _) => {
self.gate_feature("box_syntax",
e.span,
"box expression syntax is experimental in alpha release; \
"box expression syntax is experimental; \
you can call `Box::new` instead.");
}
ast::ExprLit(ref lit) => {
......
......@@ -11,13 +11,13 @@
fn main() {
use std::boxed::HEAP;
let x = box 'c'; //~ ERROR box expression syntax is experimental in alpha release
let x = box 'c'; //~ ERROR box expression syntax is experimental
println!("x: {}", x);
let x = box () 'c'; //~ ERROR box expression syntax is experimental in alpha release
let x = box () 'c'; //~ ERROR box expression syntax is experimental
println!("x: {}", x);
let x = box (HEAP) 'c'; //~ ERROR box expression syntax is experimental in alpha release
let x = box (HEAP) 'c'; //~ ERROR box expression syntax is experimental
println!("x: {}", x);
}
......@@ -9,6 +9,6 @@
// except according to those terms.
fn main() {
let box x = Box::new('c'); //~ ERROR box pattern syntax is experimental in alpha release
let box x = Box::new('c'); //~ ERROR box pattern syntax is experimental
println!("x: {}", x);
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册