#[repr(u64)]
pub enum ExitCode {
Show 24 variants Ok, SysErrSenderInvalid, SysErrSenderStateInvalid, SysErrInvalidMethod, SysErrActorPanic, SysErrInvalidReceiver, SysErrInsufficientFunds, SysErrOutOfGas, SysErrForbidden, SysErrIllegalActor, SysErrIllegalArgument, SysErrReserved2, SysErrReserved3, SysErrReserved4, SysErrReserved5, SysErrReserved6, ErrIllegalArgument, ErrNotFound, ErrForbidden, ErrInsufficientFunds, ErrIllegalState, ErrSerialization, ErrTooManyProveCommits, ErrPlaceholder,
}
Expand description

ExitCode defines the exit code from the VM execution.

Variants

Ok

SysErrSenderInvalid

Indicates failure to find an actor in the state tree.

SysErrSenderStateInvalid

Indicates failure to find the code for an actor.

SysErrInvalidMethod

Indicates failure to find a method in an actor.

SysErrActorPanic

Used for catching panics currently. (marked as unused/SysErrReserved1 in go impl though)

SysErrInvalidReceiver

Indicates a message sender has insufficient funds for a message’s execution.

SysErrInsufficientFunds

Indicates a message invocation out of sequence.

SysErrOutOfGas

Indicates message execution (including subcalls) used more gas than the specified limit.

SysErrForbidden

Indicates a message execution is forbidden for the caller.

SysErrIllegalActor

Indicates actor code performed a disallowed operation. Disallowed operations include:

  • mutating state outside of a state acquisition block
  • failing to invoke caller validation
  • aborting with a reserved exit code (including success or a system error).

SysErrIllegalArgument

Indicates an invalid argument passed to a runtime method.

SysErrReserved2

Reserved exit codes, do not use.

SysErrReserved3

SysErrReserved4

SysErrReserved5

SysErrReserved6

ErrIllegalArgument

Indicates a method parameter is invalid.

ErrNotFound

Indicates a requested resource does not exist.

ErrForbidden

Indicates an action is disallowed.

ErrInsufficientFunds

Indicates a balance of funds is insufficient.

ErrIllegalState

Indicates an actor’s internal state is invalid.

ErrSerialization

Indicates de/serialization failure within actor code.

ErrTooManyProveCommits

Power actor specific exit code.

ErrPlaceholder

Implementations

returns true if the exit code was a success

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Deserialize this value from the given Serde deserializer. Read more

Converts an i64 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an u64 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an isize to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an i8 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an i16 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an i32 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an i128 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts a usize to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an u8 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an u16 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an u32 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an u128 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts a f32 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts a f64 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Compare self to key and return true if they are equal.

Performs the conversion.

Performs the conversion.

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

Should always be Self

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.