Add FIXME
This commit is contained in:
parent
9712fa4059
commit
40809b0585
1 changed files with 2 additions and 0 deletions
|
|
@ -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);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue