# Type Alias rustc_middle::query::queries::inhabited_predicate_type::Value

source ·

    pub type Value<'tcx> = InhabitedPredicate<'tcx>;

## Aliased Type§

    enum Value<'tcx> {
        True,
        False,
        ConstIsZero(Const<'tcx>),
        NotInModule(DefId),
        GenericType(Ty<'tcx>),
        OpaqueType(OpaqueTypeKey<TyCtxt<'tcx>>),
        And(&'tcx [InhabitedPredicate<'tcx>; 2]),
        Or(&'tcx [InhabitedPredicate<'tcx>; 2]),
    }

## Variants§

§

### True

Inhabited

§

### False

Uninhabited

§

### ConstIsZero(Const<'tcx>)

Uninhabited when a const value is non-zero. This occurs when there is an array of uninhabited items, but the array is inhabited if it is empty.

§

### NotInModule(DefId)

Uninhabited if within a certain module. This occurs when an uninhabited type has restricted visibility.

§

### GenericType(Ty<'tcx>)

Inhabited if some generic type is inhabited. These are replaced by calling `Self::instantiate`.

§

### OpaqueType(OpaqueTypeKey<TyCtxt<'tcx>>)

Inhabited if either we don’t know the hidden type or we know it and it is inhabited.

§

### And(&'tcx [InhabitedPredicate<'tcx>; 2])

A AND B

§

### Or(&'tcx [InhabitedPredicate<'tcx>; 2])

A OR B

## Layout§

Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain `repr(...)` attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.

Size: 16 bytes

Size for each variant:

- `True`: 0 bytes
- `False`: 0 bytes
- `ConstIsZero`: 8 bytes
- `NotInModule`: 8 bytes
- `GenericType`: 8 bytes
- `OpaqueType`: 16 bytes
- `And`: 8 bytes
- `Or`: 8 bytes