Enum sway_core::parse_tree::declaration::function::Purity
source · [−]pub enum Purity {
Pure,
Impure,
}
Expand description
The purity of a function is related to its access of contract storage. If a function accesses or could potentially access contract storage, it is Purity::Impure. If a function does not utilize any any accesses (reads or writes) of storage, then it is Purity::Pure.
Variants
Pure
Impure
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Purity
impl UnwindSafe for Purity
Blanket Implementations
Mutably borrows from an owned value. Read more
Compare self to key
and return true
if they are equal.