s/use_mir/use_mir_borrowck/

This commit is contained in:
Niko Matsakis
2018-04-10 09:11:31 -04:00
parent 45d281d7fa
commit 96dba9358c
4 changed files with 5 additions and 5 deletions
+1 -1
View File
@@ -303,7 +303,7 @@ pub fn report_region_errors(
) {
debug!("report_region_errors(): {} errors to start", errors.len());
if will_later_be_reported_by_nll && self.tcx.use_mir() {
if will_later_be_reported_by_nll && self.tcx.use_mir_borrowck() {
// With `#![feature(nll)]`, we want to present a nice user
// experience, so don't even mention the errors from the
// AST checker.
+2 -2
View File
@@ -1473,7 +1473,7 @@ pub fn serialize_query_result_cache<E>(self,
/// If true, we should use the MIR-based borrowck (we may *also* use
/// the AST-based borrowck).
pub fn use_mir(self) -> bool {
pub fn use_mir_borrowck(self) -> bool {
self.borrowck_mode().use_mir()
}
@@ -1508,7 +1508,7 @@ pub fn borrowck_mode(&self) -> BorrowckMode {
pub fn emit_end_regions(self) -> bool {
self.sess.opts.debugging_opts.emit_end_regions ||
self.sess.opts.debugging_opts.mir_emit_validate > 0 ||
self.use_mir()
self.use_mir_borrowck()
}
#[inline]
+1 -1
View File
@@ -73,7 +73,7 @@ fn mir_borrowck<'a, 'tcx>(
let input_mir = tcx.mir_validated(def_id);
debug!("run query mir_borrowck: {}", tcx.item_path_str(def_id));
if !tcx.has_attr(def_id, "rustc_mir_borrowck") && !tcx.use_mir() {
if !tcx.has_attr(def_id, "rustc_mir_borrowck") && !tcx.use_mir_borrowck() {
return None;
}
@@ -1596,7 +1596,7 @@ fn run_pass<'a, 'tcx>(&self, tcx: TyCtxt<'a, 'tcx, 'tcx>, src: MirSource, mir: &
// When NLL is enabled, the borrow checker runs the typeck
// itself, so we don't need this MIR pass anymore.
if tcx.use_mir() {
if tcx.use_mir_borrowck() {
return;
}