Struct sway_core::parse_tree::declaration::StorageField
source · [−]pub struct StorageField {
pub name: Ident,
pub type: TypeInfo,
pub initializer: Expression,
}
Expand description
An individual field in a storage declaration. A type annotation and initializer value must be provided. The initializer value must be a constant expression. For now, that basically means just a literal, but as constant folding improves, we can update that.
Fields
name: Ident
type: TypeInfo
initializer: Expression
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for StorageField
impl Send for StorageField
impl Sync for StorageField
impl Unpin for StorageField
impl UnwindSafe for StorageField
Blanket Implementations
Mutably borrows from an owned value. Read more