explain why we don't need to run type-checker when NLL is enabled
This commit is contained in:
parent
2370b60529
commit
bcd996857e
1 changed files with 2 additions and 0 deletions
|
|
@ -1585,6 +1585,8 @@ impl MirPass for TypeckMir {
|
|||
let id = tcx.hir.as_local_node_id(def_id).unwrap();
|
||||
debug!("run_pass: {:?}", def_id);
|
||||
|
||||
// When NLL is enabled, the borrow checker runs the typeck
|
||||
// itself, so we don't need this MIR pass anymore.
|
||||
if tcx.sess.nll() {
|
||||
return;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue