Skip to content

Commit

Permalink
Merge pull request #410 from RalfJung/rustup
Browse files Browse the repository at this point in the history
fix for latest rust nightly
  • Loading branch information
RalfJung authored Jul 17, 2018
2 parents f18fc27 + 72756b7 commit 911aedf
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 22 deletions.
21 changes: 1 addition & 20 deletions rustc_tests/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion rustc_tests/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ fn after_analysis<'a, 'tcx>(state: &mut CompileState<'a, 'tcx>) {
struct Visitor<'a, 'tcx: 'a>(TyCtxt<'a, 'tcx, 'tcx>, &'a CompileState<'a, 'tcx>);
impl<'a, 'tcx: 'a, 'hir> itemlikevisit::ItemLikeVisitor<'hir> for Visitor<'a, 'tcx> {
fn visit_item(&mut self, i: &'hir hir::Item) {
if let hir::Item_::ItemFn(.., body_id) = i.node {
if let hir::ItemKind::Fn(.., body_id) = i.node {
if i.attrs.iter().any(|attr| attr.name() == "test") {
let did = self.0.hir.body_owner_def_id(body_id);
println!("running test: {}", self.0.def_path_debug_str(did));
Expand Down
2 changes: 1 addition & 1 deletion src/bin/miri.rs
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ fn after_analysis<'a, 'tcx>(state: &mut CompileState<'a, 'tcx>, use_start_fn: bo
);
impl<'a, 'tcx: 'a, 'hir> itemlikevisit::ItemLikeVisitor<'hir> for Visitor<'a, 'tcx> {
fn visit_item(&mut self, i: &'hir hir::Item) {
if let hir::Item_::ItemFn(.., body_id) = i.node {
if let hir::ItemKind::Fn(.., body_id) = i.node {
if i.attrs.iter().any(|attr| {
attr.name() == "test"
})
Expand Down

0 comments on commit 911aedf

Please sign in to comment.