提交 99347591 编写于 作者: C Cameron Zwarich

Remove an unused bkcerr_code constructor parameter

The RestrictionSet parameter of the err_borrowed_pointer_too_short
constructor isn't  actually used, so it can be removed.
上级 6849362f
......@@ -133,7 +133,7 @@ fn restrict(&self,
cause: self.cause,
cmt: cmt_base,
code: err_borrowed_pointer_too_short(
self.loan_region, lt, restrictions)});
self.loan_region, lt)});
return Safe;
}
Safe
......@@ -148,7 +148,7 @@ fn restrict(&self,
cause: self.cause,
cmt: cmt_base,
code: err_borrowed_pointer_too_short(
self.loan_region, lt, restrictions)});
self.loan_region, lt)});
return Safe;
}
......
......@@ -310,8 +310,7 @@ fn repr(&self, _tcx: &ty::ctxt) -> String {
pub enum bckerr_code {
err_mutbl,
err_out_of_scope(ty::Region, ty::Region), // superscope, subscope
err_borrowed_pointer_too_short(
ty::Region, ty::Region, RestrictionSet), // loan, ptr
err_borrowed_pointer_too_short(ty::Region, ty::Region), // loan, ptr
}
// Combination of an error code and the categorization of the expression
......@@ -711,7 +710,7 @@ pub fn note_and_explain_bckerr(&self, err: BckError) {
suggestion);
}
err_borrowed_pointer_too_short(loan_scope, ptr_scope, _) => {
err_borrowed_pointer_too_short(loan_scope, ptr_scope) => {
let descr = match opt_loan_path(&err.cmt) {
Some(lp) => {
format!("`{}`", self.loan_path_to_str(&*lp))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册