File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
src/librustc_mir/dataflow Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -23,11 +23,13 @@ use crate::dataflow::BottomValue;
23
23
///
24
24
/// ```ignore(cross-crate-imports)
25
25
/// fn do_my_analysis(body: &mir::Body<'tcx>, dead_unwinds: &BitSet<BasicBlock>) {
26
+ /// // `MyAnalysis` implements `Analysis`.
26
27
/// let analysis = MyAnalysis::new();
28
+ ///
27
29
/// let results = Engine::new(body, dead_unwinds, analysis).iterate_to_fixpoint();
28
- /// let mut cursor = dataflow:: ResultsCursor::new(body, results);
30
+ /// let mut cursor = ResultsCursor::new(body, results);
29
31
///
30
- /// for statement_index in body.block_data[START_BLOCK].statements.iter () {
32
+ /// for (_, statement_index) in body.block_data[START_BLOCK].statements.iter_enumerated () {
31
33
/// cursor.seek_after(Location { block: START_BLOCK, statement_index });
32
34
/// let state = cursor.get();
33
35
/// println!("{:?}", state);
You can’t perform that action at this time.
0 commit comments