2019-03-15 22:42:35 +00:00
|
|
|
package vm
|
|
|
|
|
2019-03-16 21:52:05 +00:00
|
|
|
//Vmstate represents all possible states that the neo-vm can be in
|
|
|
|
type Vmstate byte
|
2019-03-15 22:42:35 +00:00
|
|
|
|
2019-03-17 18:31:58 +00:00
|
|
|
// List of possible vm states
|
2019-03-15 22:42:35 +00:00
|
|
|
const (
|
2019-03-17 20:21:48 +00:00
|
|
|
// NONE is the running state of the vm
|
|
|
|
// NONE signifies that the vm is ready to process an opcode
|
|
|
|
NONE = 0
|
|
|
|
// HALT is a stopped state of the vm
|
|
|
|
// where the stop was signalled by the program completion
|
|
|
|
HALT = 1 << 0
|
|
|
|
// FAULT is a stopped state of the vm
|
|
|
|
// where the stop was signalled by an error in the program
|
2019-03-15 22:42:35 +00:00
|
|
|
FAULT = 1 << 1
|
2019-03-17 20:21:48 +00:00
|
|
|
// BREAK is a suspended state for the VM
|
|
|
|
// were the break was signalled by a breakpoint
|
2019-03-15 22:42:35 +00:00
|
|
|
BREAK = 1 << 2
|
|
|
|
)
|