pub struct Constant {
pub ty: Type,
pub value: ConstantValue,
}Expand description
A Type and constant value, including ConstantValue::Undef for uninitialized constants.
Fields
ty: Typevalue: ConstantValueImplementations
value must be created as an array constant first, using Constant::new_array().
value must be created as a struct constant first, using Constant::new_struct().
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Constant
impl UnwindSafe for Constant
Blanket Implementations
Mutably borrows from an owned value. Read more