Merge pull request #1711 from Gustav-Simonsson/timestamp_big_int
Add tests for uncle timestamps and refactor timestamp type (cherry picked from commitabce09954b
) (cherry picked from commitfd512fa12c
) Conflicts: core/vm/instructions.go core/vm/jit_test.go
This commit is contained in:
committed by
Gustav Simonsson
parent
5c11d1033d
commit
2d1ea1a66d
@ -33,7 +33,7 @@ type Environment interface {
|
||||
BlockNumber() *big.Int
|
||||
GetHash(n uint64) common.Hash
|
||||
Coinbase() common.Address
|
||||
Time() uint64
|
||||
Time() *big.Int
|
||||
Difficulty() *big.Int
|
||||
GasLimit() *big.Int
|
||||
Transfer(from, to Account, amount *big.Int) error
|
||||
|
@ -461,7 +461,7 @@ func (self *Vm) Run(context *Context, input []byte) (ret []byte, err error) {
|
||||
case TIMESTAMP:
|
||||
time := self.env.Time()
|
||||
|
||||
stack.push(new(big.Int).SetUint64(time))
|
||||
stack.push(new(big.Int).Set(time))
|
||||
|
||||
case NUMBER:
|
||||
number := self.env.BlockNumber()
|
||||
|
Reference in New Issue
Block a user