aboutsummaryrefslogtreecommitdiffstats
path: root/core/vm/stack.go
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2015-06-16 01:28:48 +0800
committerobscuren <geffobscura@gmail.com>2015-06-16 01:28:48 +0800
commit5daf8729be88eca87b302ebf7a46fc69cad0f6d0 (patch)
tree0053cb5b84978645b3c83895a651c512e081a183 /core/vm/stack.go
parentbac9a94ddf20dc530966cbf6cd384aaf94aedc77 (diff)
parent4673b04503742de9b1622557b44135d6a4934ad6 (diff)
downloadgo-tangerine-0.9.30.tar
go-tangerine-0.9.30.tar.gz
go-tangerine-0.9.30.tar.bz2
go-tangerine-0.9.30.tar.lz
go-tangerine-0.9.30.tar.xz
go-tangerine-0.9.30.tar.zst
go-tangerine-0.9.30.zip
Merge branch 'release/0.9.30'v0.9.30
Diffstat (limited to 'core/vm/stack.go')
-rw-r--r--core/vm/stack.go6
1 files changed, 5 insertions, 1 deletions
diff --git a/core/vm/stack.go b/core/vm/stack.go
index bb232d0b9..2be5c3dbe 100644
--- a/core/vm/stack.go
+++ b/core/vm/stack.go
@@ -5,7 +5,7 @@ import (
"math/big"
)
-func newStack() *stack {
+func newstack() *stack {
return &stack{}
}
@@ -14,6 +14,10 @@ type stack struct {
ptr int
}
+func (st *stack) Data() []*big.Int {
+ return st.data[:st.ptr]
+}
+
func (st *stack) push(d *big.Int) {
// NOTE push limit (1024) is checked in baseCheck
stackItem := new(big.Int).Set(d)