diff options
| author | Felix S. Klock II <pnkfelix@pnkfx.org> | 2017-08-22 12:05:52 +0200 |
|---|---|---|
| committer | Felix S. Klock II <pnkfelix@pnkfx.org> | 2017-08-22 12:05:52 +0200 |
| commit | fbb099edca7003b86e98e1f41800ea35e030e657 (patch) | |
| tree | eb49e58ea3ccf413f97243f2783368f0cd2bd1a8 /src | |
| parent | 6722996923157f2089cd5d7ead10f79162e0abb0 (diff) | |
| download | rust-fbb099edca7003b86e98e1f41800ea35e030e657.tar.gz rust-fbb099edca7003b86e98e1f41800ea35e030e657.zip | |
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.)
Diffstat (limited to 'src')
| -rw-r--r-- | src/librustc_mir/borrow_check.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustc_mir/borrow_check.rs b/src/librustc_mir/borrow_check.rs index 5ae3bee3267..eda2bacb11f 100644 --- a/src/librustc_mir/borrow_check.rs +++ b/src/librustc_mir/borrow_check.rs @@ -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; } |
