From 4cd79d8ddd7608d60344b13fe4bda7315429d1d9 Mon Sep 17 00:00:00 2001 From: obscuren Date: Tue, 23 Dec 2014 13:48:44 +0100 Subject: Refactored block & Transaction * Includes new rlp decoder --- xeth/vm_env.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'xeth/vm_env.go') diff --git a/xeth/vm_env.go b/xeth/vm_env.go index 7fb674a94..7633e0640 100644 --- a/xeth/vm_env.go +++ b/xeth/vm_env.go @@ -28,15 +28,15 @@ func NewEnv(state *state.StateDB, block *types.Block, value *big.Int, sender []b } func (self *VMEnv) Origin() []byte { return self.sender } -func (self *VMEnv) BlockNumber() *big.Int { return self.block.Number } -func (self *VMEnv) PrevHash() []byte { return self.block.PrevHash } -func (self *VMEnv) Coinbase() []byte { return self.block.Coinbase } -func (self *VMEnv) Time() int64 { return self.block.Time } -func (self *VMEnv) Difficulty() *big.Int { return self.block.Difficulty } +func (self *VMEnv) BlockNumber() *big.Int { return self.block.Number() } +func (self *VMEnv) PrevHash() []byte { return self.block.ParentHash() } +func (self *VMEnv) Coinbase() []byte { return self.block.Coinbase() } +func (self *VMEnv) Time() int64 { return self.block.Time() } +func (self *VMEnv) Difficulty() *big.Int { return self.block.Difficulty() } func (self *VMEnv) BlockHash() []byte { return self.block.Hash() } +func (self *VMEnv) GasLimit() *big.Int { return self.block.GasLimit() } func (self *VMEnv) Value() *big.Int { return self.value } func (self *VMEnv) State() *state.StateDB { return self.state } -func (self *VMEnv) GasLimit() *big.Int { return self.block.GasLimit } func (self *VMEnv) Depth() int { return self.depth } func (self *VMEnv) SetDepth(i int) { self.depth = i } func (self *VMEnv) AddLog(log state.Log) { -- cgit