diff options
author | obscuren <geffobscura@gmail.com> | 2014-10-18 19:31:20 +0800 |
---|---|---|
committer | obscuren <geffobscura@gmail.com> | 2014-10-18 19:31:20 +0800 |
commit | 20c742e47406c13ebc6427951f6fcf1b0056ea26 (patch) | |
tree | e8112a93626c0f20ca5aa9ac91ea2d1be07150d9 /ethchain/state_transition.go | |
parent | a02dc4ccc321bdee2a670eecdf5c3bac01fc290b (diff) | |
download | dexon-20c742e47406c13ebc6427951f6fcf1b0056ea26.tar dexon-20c742e47406c13ebc6427951f6fcf1b0056ea26.tar.gz dexon-20c742e47406c13ebc6427951f6fcf1b0056ea26.tar.bz2 dexon-20c742e47406c13ebc6427951f6fcf1b0056ea26.tar.lz dexon-20c742e47406c13ebc6427951f6fcf1b0056ea26.tar.xz dexon-20c742e47406c13ebc6427951f6fcf1b0056ea26.tar.zst dexon-20c742e47406c13ebc6427951f6fcf1b0056ea26.zip |
Moved ethvm => vm
Diffstat (limited to 'ethchain/state_transition.go')
-rw-r--r-- | ethchain/state_transition.go | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/ethchain/state_transition.go b/ethchain/state_transition.go index 5bb084ae4..79321eaac 100644 --- a/ethchain/state_transition.go +++ b/ethchain/state_transition.go @@ -7,7 +7,7 @@ import ( "github.com/ethereum/eth-go/ethstate" "github.com/ethereum/eth-go/ethtrie" "github.com/ethereum/eth-go/ethutil" - "github.com/ethereum/eth-go/ethvm" + "github.com/ethereum/eth-go/vm" ) /* @@ -160,13 +160,13 @@ func (self *StateTransition) TransitionState() (err error) { sender.Nonce += 1 // Transaction gas - if err = self.UseGas(ethvm.GasTx); err != nil { + if err = self.UseGas(vm.GasTx); err != nil { return } // Pay data gas dataPrice := big.NewInt(int64(len(self.data))) - dataPrice.Mul(dataPrice, ethvm.GasData) + dataPrice.Mul(dataPrice, vm.GasData) if err = self.UseGas(dataPrice); err != nil { return } @@ -261,11 +261,11 @@ func (self *StateTransition) Eval(msg *ethstate.Message, script []byte, context transactor = self.Sender() state = self.state env = NewEnv(state, self.tx, self.block) - callerClosure = ethvm.NewClosure(msg, transactor, context, script, self.gas, self.gasPrice) + callerClosure = vm.NewClosure(msg, transactor, context, script, self.gas, self.gasPrice) ) - //vm := ethvm.New(env, ethvm.Type(ethutil.Config.VmType)) - vm := ethvm.New(env, ethvm.DebugVmTy) + //vm := vm.New(env, vm.Type(ethutil.Config.VmType)) + vm := vm.New(env, vm.DebugVmTy) ret, _, err = callerClosure.Call(vm, self.tx.Data) |