Moved execution from vm to chain.
This moves call and create to the specified environments. Vms are no longer re-used. Vm uses environment's Call(Code) and Create in order to execute new contracts or transfer value between accounts. State transition now uses the same mechanism described above.
This commit is contained in:
@ -276,15 +276,14 @@ func (c *StateObject) Init() Code {
|
||||
return c.InitCode
|
||||
}
|
||||
|
||||
// To satisfy ClosureRef
|
||||
func (self *StateObject) Object() *StateObject {
|
||||
return self
|
||||
}
|
||||
|
||||
func (self *StateObject) Root() []byte {
|
||||
return self.State.Trie.GetRoot()
|
||||
}
|
||||
|
||||
func (self *StateObject) SetCode(code []byte) {
|
||||
self.Code = code
|
||||
}
|
||||
|
||||
//
|
||||
// Encoding
|
||||
//
|
||||
|
Reference in New Issue
Block a user