Fix logic error in test guarding prototype MIR borrowck code.

(This crept in during the shift from a transform to a query; I didn't
notice because my muscle memory was still always passing `-Z
mir-borrowck`, while my test cases *also* had the
`#[rustc_mir_borrowck]` attribute attached to them.)
This commit is contained in:
Felix S. Klock II 2017-08-22 12:05:52 +02:00
parent 6722996923
commit fbb099edca

View file

@ -50,7 +50,7 @@ fn mir_borrowck<'a, 'tcx>(tcx: TyCtxt<'a, 'tcx, 'tcx>, def_id: DefId) {
debug!("run query mir_borrowck: {}", tcx.node_path_str(src.item_id()));
let mir: &Mir<'tcx> = &mir.borrow();
if !tcx.has_attr(def_id, "rustc_mir_borrowck") || !tcx.sess.opts.debugging_opts.borrowck_mir {
if !tcx.has_attr(def_id, "rustc_mir_borrowck") && !tcx.sess.opts.debugging_opts.borrowck_mir {
return;
}