We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3e7a5a4 commit 2869abaCopy full SHA for 2869aba
src/librustc_mir/interpret/place.rs
@@ -658,6 +658,13 @@ where
658
PlaceTy {
659
place: match self.frame().return_place {
660
Some(p) => *p,
661
+ // Even if we don't have a return place, we sometimes need to
662
+ // create this place, but any attempt to read from / write to it
663
+ // (even a ZST read/write) needs to error, so let us make this
664
+ // a NULL place.
665
+ //
666
+ // FIXME: Ideally we'd make sure that the place projections also
667
+ // bail out.
668
None => Place::null(&*self),
669
},
670
layout: self.layout_of(
0 commit comments