Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit 9dd3c4b

Browse files
NoraCodesMark-Simulacrum
authored andcommitted
Don't re-export std::ops::ControlFlow in the compiler.
1 parent a458298 commit 9dd3c4b

File tree

2 files changed

+3
-4
lines changed
  • compiler
    • rustc_data_structures/src/graph/iterate
    • rustc_mir_build/src

2 files changed

+3
-4
lines changed

compiler/rustc_data_structures/src/graph/iterate/mod.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
use super::{DirectedGraph, WithNumNodes, WithStartNode, WithSuccessors};
22
use rustc_index::bit_set::BitSet;
33
use rustc_index::vec::IndexVec;
4+
use std::ops::ControlFlow;
45

56
#[cfg(test)]
67
mod tests;
@@ -86,9 +87,6 @@ where
8687
}
8788
}
8889

89-
/// Allows searches to terminate early with a value.
90-
pub use std::ops::ControlFlow;
91-
9290
/// The status of a node in the depth-first search.
9391
///
9492
/// See the documentation of `TriColorDepthFirstSearch` to see how a node's status is updated

compiler/rustc_mir_build/src/lints.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use rustc_data_structures::graph::iterate::{
2-
ControlFlow, NodeStatus, TriColorDepthFirstSearch, TriColorVisitor,
2+
NodeStatus, TriColorDepthFirstSearch, TriColorVisitor,
33
};
44
use rustc_hir::def_id::LocalDefId;
55
use rustc_hir::intravisit::FnKind;
@@ -9,6 +9,7 @@ use rustc_middle::ty::subst::{GenericArg, InternalSubsts};
99
use rustc_middle::ty::{self, AssocItem, AssocItemContainer, Instance, TyCtxt};
1010
use rustc_session::lint::builtin::UNCONDITIONAL_RECURSION;
1111
use rustc_span::Span;
12+
use std::ops::ControlFlow;
1213

1314
crate fn check<'tcx>(tcx: TyCtxt<'tcx>, body: &Body<'tcx>, def_id: LocalDefId) {
1415
let hir_id = tcx.hir().local_def_id_to_hir_id(def_id);

0 commit comments

Comments
 (0)