aboutsummaryrefslogtreecommitdiffstats
path: root/ethpipe/world.go
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2014-08-05 17:10:24 +0800
committerobscuren <geffobscura@gmail.com>2014-08-05 17:10:24 +0800
commit4f0bda403ea332eeb477f8e56457423628772b19 (patch)
treea601453b364160a3af94ee324e198fcb304fc5a4 /ethpipe/world.go
parentc215bbadf13ec70e4d1b65e67d4ff4568d644542 (diff)
downloadgo-tangerine-4f0bda403ea332eeb477f8e56457423628772b19.tar
go-tangerine-4f0bda403ea332eeb477f8e56457423628772b19.tar.gz
go-tangerine-4f0bda403ea332eeb477f8e56457423628772b19.tar.bz2
go-tangerine-4f0bda403ea332eeb477f8e56457423628772b19.tar.lz
go-tangerine-4f0bda403ea332eeb477f8e56457423628772b19.tar.xz
go-tangerine-4f0bda403ea332eeb477f8e56457423628772b19.tar.zst
go-tangerine-4f0bda403ea332eeb477f8e56457423628772b19.zip
Added vm options for object execution
Diffstat (limited to 'ethpipe/world.go')
-rw-r--r--ethpipe/world.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/ethpipe/world.go b/ethpipe/world.go
index 42e19fe00..25e2a1952 100644
--- a/ethpipe/world.go
+++ b/ethpipe/world.go
@@ -26,17 +26,17 @@ func (self *world) State() *ethstate.State {
return self.pipe.stateManager.CurrentState()
}
-func (self *world) Get(addr []byte) *ethstate.StateObject {
- return self.State().GetStateObject(addr)
+func (self *world) Get(addr []byte) *object {
+ return &object{self.State().GetStateObject(addr)}
}
func (self *world) safeGet(addr []byte) *ethstate.StateObject {
- object := self.Get(addr)
- if object != nil {
- return object
+ object := self.State().GetStateObject(addr)
+ if object == nil {
+ object = ethstate.NewStateObject(addr)
}
- return ethstate.NewStateObject(addr)
+ return object
}
func (self *world) Coinbase() *ethstate.StateObject {