Skip to content

Commit

Permalink
Add FIXME
Browse files Browse the repository at this point in the history
  • Loading branch information
oli-obk authored Mar 6, 2020
1 parent 9712fa4 commit 40809b0
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/librustc_mir/interpret/place.rs
Original file line number Diff line number Diff line change
Expand Up @@ -413,6 +413,8 @@ where
// This is a narrow bug-fix for rust-lang/rust#69191: if we are
// trying to access absent field of uninhabited variant, then
// signal UB (but don't ICE the compiler).
// FIXME temporary hack to work around incoherence between
// layout computation and MIR building
if field >= count as u64 && base.layout.abi == layout::Abi::Uninhabited {
throw_ub!(Unreachable);
}
Expand Down

0 comments on commit 40809b0

Please sign in to comment.