aboutsummaryrefslogtreecommitdiffstats
path: root/accounts/abi/numbers.go
diff options
context:
space:
mode:
authorzelig <viktor.tron@gmail.com>2015-03-16 23:46:29 +0800
committerzelig <viktor.tron@gmail.com>2015-03-16 23:46:29 +0800
commit5e7702fd050ed5520a03cc2cfc8b1f45a70f35fb (patch)
treed5ba6197a8c0c8e36bb92ee9fc8aad717cb2d178 /accounts/abi/numbers.go
parent8393dab470c40678caf36ada82e312d29c4cf5c4 (diff)
parent22893b7ac925c49168c119f293ea8befc3aff5cc (diff)
downloaddexon-5e7702fd050ed5520a03cc2cfc8b1f45a70f35fb.tar
dexon-5e7702fd050ed5520a03cc2cfc8b1f45a70f35fb.tar.gz
dexon-5e7702fd050ed5520a03cc2cfc8b1f45a70f35fb.tar.bz2
dexon-5e7702fd050ed5520a03cc2cfc8b1f45a70f35fb.tar.lz
dexon-5e7702fd050ed5520a03cc2cfc8b1f45a70f35fb.tar.xz
dexon-5e7702fd050ed5520a03cc2cfc8b1f45a70f35fb.tar.zst
dexon-5e7702fd050ed5520a03cc2cfc8b1f45a70f35fb.zip
Merge remote-tracking branch 'upstream/develop' into frontier/js
Conflicts: cmd/ethereum/js.go javascript/types.go
Diffstat (limited to 'accounts/abi/numbers.go')
-rw-r--r--accounts/abi/numbers.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/accounts/abi/numbers.go b/accounts/abi/numbers.go
index 378f6541e..9205c005e 100644
--- a/accounts/abi/numbers.go
+++ b/accounts/abi/numbers.go
@@ -4,7 +4,7 @@ import (
"math/big"
"reflect"
- "github.com/ethereum/go-ethereum/ethutil"
+ "github.com/ethereum/go-ethereum/common"
)
var big_t = reflect.TypeOf(&big.Int{})
@@ -38,13 +38,13 @@ var big_ts = reflect.TypeOf([]*big.Int(nil))
// U256 will ensure unsigned 256bit on big nums
func U256(n *big.Int) []byte {
- return ethutil.LeftPadBytes(ethutil.U256(n).Bytes(), 32)
+ return common.LeftPadBytes(common.U256(n).Bytes(), 32)
}
func S256(n *big.Int) []byte {
- sint := ethutil.S256(n)
- ret := ethutil.LeftPadBytes(sint.Bytes(), 32)
- if sint.Cmp(ethutil.Big0) < 0 {
+ sint := common.S256(n)
+ ret := common.LeftPadBytes(sint.Bytes(), 32)
+ if sint.Cmp(common.Big0) < 0 {
for i, b := range ret {
if b == 0 {
ret[i] = 1