diff options
| author | Ralf Jung <post@ralfj.de> | 2018-10-17 09:24:43 +0200 |
|---|---|---|
| committer | Ralf Jung <post@ralfj.de> | 2018-10-17 09:24:43 +0200 |
| commit | c31819b3ff35be5bdec58cba9515578fbff0a5b8 (patch) | |
| tree | 57b1572e21f090ee11497e816b9245f3886da9b6 | |
| parent | 37ba1071c626c43a5b85752b4ffcf6a87e2b745e (diff) | |
| download | rust-c31819b3ff35be5bdec58cba9515578fbff0a5b8.tar.gz rust-c31819b3ff35be5bdec58cba9515578fbff0a5b8.zip | |
layout should not affect CTFE checks (outside of validation)
| -rw-r--r-- | src/librustc_mir/interpret/operand.rs | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/src/librustc_mir/interpret/operand.rs b/src/librustc_mir/interpret/operand.rs index c72a5894b6a..2d6b19ca4a7 100644 --- a/src/librustc_mir/interpret/operand.rs +++ b/src/librustc_mir/interpret/operand.rs @@ -688,9 +688,6 @@ impl<'a, 'mir, 'tcx, M: Machine<'a, 'mir, 'tcx>> EvalContext<'a, 'mir, 'tcx, M> rval: OpTy<'tcx, M::PointerTag>, ) -> EvalResult<'tcx, (u128, usize)> { trace!("read_discriminant_value {:#?}", rval.layout); - if rval.layout.abi.is_uninhabited() { - return err!(Unreachable); - } match rval.layout.variants { layout::Variants::Single { index } => { |
