File tree 1 file changed +4
-4
lines changed
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -127,19 +127,19 @@ For example, the following code uses a [`ResultsVisitor`]...
127
127
128
128
``` rust,ignore
129
129
// Assuming `MyVisitor` implements `ResultsVisitor<FlowState = MyAnalysis::Domain>`...
130
- let my_visitor = MyVisitor::new();
130
+ let mut my_visitor = MyVisitor::new();
131
131
132
132
// inspect the fixpoint state for every location within every block in RPO.
133
- let results = MyAnalysis()
133
+ let results = MyAnalysis::new ()
134
134
.into_engine(tcx, body, def_id)
135
135
.iterate_to_fixpoint()
136
- .visit_with (body, traversal::reverse_postorder(body) , &mut my_visitor);
136
+ .visit_in_rpo_with (body, &mut my_visitor);
137
137
```
138
138
139
139
whereas this code uses [ ` ResultsCursor ` ] :
140
140
141
141
``` rust,ignore
142
- let mut results = MyAnalysis()
142
+ let mut results = MyAnalysis::new ()
143
143
.into_engine(tcx, body, def_id)
144
144
.iterate_to_fixpoint()
145
145
.into_results_cursor(body);
You can’t perform that action at this time.
0 commit comments