rustc: Remove obsolete error_out_of_root_scope variant

This commit is contained in:
Flavio Percoco
2014-04-17 01:00:00 +02:00
parent fa43f6a7a6
commit e80089576e
-17
View File
@@ -334,7 +334,6 @@ fn repr(&self, _tcx: &ty::ctxt) -> ~str {
#[deriving(Eq)]
pub enum bckerr_code {
err_mutbl,
err_out_of_root_scope(ty::Region, ty::Region), // superscope, subscope
err_out_of_scope(ty::Region, ty::Region), // superscope, subscope
err_borrowed_pointer_too_short(
ty::Region, ty::Region, RestrictionSet), // loan, ptr
@@ -616,9 +615,6 @@ pub fn bckerr_to_str(&self, err: &BckError) -> ~str {
}
}
}
err_out_of_root_scope(..) => {
format!("cannot root managed value long enough")
}
err_out_of_scope(..) => {
let msg = match opt_loan_path(&err.cmt) {
None => format!("borrowed value"),
@@ -694,19 +690,6 @@ pub fn note_and_explain_bckerr(&self, err: BckError) {
match code {
err_mutbl(..) => { }
err_out_of_root_scope(super_scope, sub_scope) => {
note_and_explain_region(
self.tcx,
"managed value would have to be rooted for ",
sub_scope,
"...");
note_and_explain_region(
self.tcx,
"...but can only be rooted for ",
super_scope,
"");
}
err_out_of_scope(super_scope, sub_scope) => {
note_and_explain_region(
self.tcx,