Skip to content

Commit 086b98f

Browse files
committed
return pointer had wrong index
1 parent ef1dd41 commit 086b98f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/rustc_mir/src/dataflow/impls/available_locals.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ impl LocalWithLocationMap {
156156
);
157157

158158
// return pointer
159-
map.entry(body.local_decls.next_index())
159+
map.entry(body.local_decls.indices().next().unwrap())
160160
.or_insert(SmallVec::with_capacity(2))
161161
.push((0usize.into(), None));
162162

0 commit comments

Comments
 (0)