This repository was archived by the owner on May 28, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +5
-6
lines changed
compiler/rustc_mir_dataflow/src Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -752,7 +752,7 @@ impl Map {
752752 let old = self . projections . insert ( ( place, TrackElem :: Discriminant ) , discr) ;
753753 assert ! ( old. is_none( ) ) ;
754754
755- // Allocate a value slot if it doesn't have one.
755+ // Allocate a value slot since it doesn't have one.
756756 assert ! ( self . places[ discr] . value_index. is_none( ) ) ;
757757 self . places [ discr] . value_index = Some ( self . value_count . into ( ) ) ;
758758 self . value_count += 1 ;
@@ -769,11 +769,10 @@ impl Map {
769769 let old = self . projections . insert ( ( place, TrackElem :: DerefLen ) , len) ;
770770 assert ! ( old. is_none( ) ) ;
771771
772- // Allocate a value slot if it doesn't have one.
773- if self . places [ len] . value_index . is_none ( ) {
774- self . places [ len] . value_index = Some ( self . value_count . into ( ) ) ;
775- self . value_count += 1 ;
776- }
772+ // Allocate a value slot since it doesn't have one.
773+ assert ! ( self . places[ len] . value_index. is_none( ) ) ;
774+ self . places [ len] . value_index = Some ( self . value_count . into ( ) ) ;
775+ self . value_count += 1 ;
777776 }
778777
779778 // Recurse with all fields of this place.
You can’t perform that action at this time.
0 commit comments