VM: Add stackItems; Array, Boolean, Int and ByteArray

This commit is contained in:
BlockChainDev 2019-02-27 20:55:48 +00:00
parent e29b85d0d7
commit d8d27761ae
4 changed files with 77 additions and 0 deletions

13
pkg/vm/stack/array.go Normal file
View file

@ -0,0 +1,13 @@
package stack
// Array represents an Array of stackItems on the stack
type Array struct {
*abstractItem
val []Item
}
// Array overrides the default implementation
// by the abstractItem, returning an Array struct
func (a *Array) Array() (*Array, error) {
return a, nil
}