Unify variadic errors
This commit is contained in:
parent
2287b4b628
commit
3f9fc39ab9
1 changed files with 1 additions and 1 deletions
|
@ -1550,7 +1550,7 @@ pub fn ast_ty_to_ty<'tcx>(this: &AstConv<'tcx>,
|
||||||
ast::TyParen(ref typ) => ast_ty_to_ty(this, rscope, &**typ),
|
ast::TyParen(ref typ) => ast_ty_to_ty(this, rscope, &**typ),
|
||||||
ast::TyBareFn(ref bf) => {
|
ast::TyBareFn(ref bf) => {
|
||||||
if bf.decl.variadic && bf.abi != abi::C {
|
if bf.decl.variadic && bf.abi != abi::C {
|
||||||
span_err!(tcx.sess, ast_ty.span, E0222,
|
span_err!(tcx.sess, ast_ty.span, E0045,
|
||||||
"variadic function must have C calling convention");
|
"variadic function must have C calling convention");
|
||||||
}
|
}
|
||||||
let bare_fn = ty_of_bare_fn(this, bf.unsafety, bf.abi, &*bf.decl);
|
let bare_fn = ty_of_bare_fn(this, bf.unsafety, bf.abi, &*bf.decl);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue