aboutsummaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2015-05-31 21:53:17 +0800
committerobscuren <geffobscura@gmail.com>2015-06-04 04:39:17 +0800
commitb26f5e0bb7e8922c80bc3513d1ebce2c99a081f5 (patch)
tree941b22f81006fd88655fc3266debf9d2a556915d /common
parentfa4aefee44c5dd32fb7e0d02960c1550e9c8a330 (diff)
downloadgo-tangerine-b26f5e0bb7e8922c80bc3513d1ebce2c99a081f5.tar
go-tangerine-b26f5e0bb7e8922c80bc3513d1ebce2c99a081f5.tar.gz
go-tangerine-b26f5e0bb7e8922c80bc3513d1ebce2c99a081f5.tar.bz2
go-tangerine-b26f5e0bb7e8922c80bc3513d1ebce2c99a081f5.tar.lz
go-tangerine-b26f5e0bb7e8922c80bc3513d1ebce2c99a081f5.tar.xz
go-tangerine-b26f5e0bb7e8922c80bc3513d1ebce2c99a081f5.tar.zst
go-tangerine-b26f5e0bb7e8922c80bc3513d1ebce2c99a081f5.zip
types: block json unmarshal method added
Diffstat (limited to 'common')
-rw-r--r--common/big.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/common/big.go b/common/big.go
index 3257b179d..05d56daba 100644
--- a/common/big.go
+++ b/common/big.go
@@ -36,16 +36,16 @@ func Big(num string) *big.Int {
return n
}
-// BigD
+// Bytes2Big
//
-// Shortcut for new(big.Int).SetBytes(...)
-func Bytes2Big(data []byte) *big.Int {
+func BytesToBig(data []byte) *big.Int {
n := new(big.Int)
n.SetBytes(data)
return n
}
-func BigD(data []byte) *big.Int { return Bytes2Big(data) }
+func Bytes2Big(data []byte) *big.Int { return BytesToBig(data) }
+func BigD(data []byte) *big.Int { return BytesToBig(data) }
func String2Big(num string) *big.Int {
n := new(big.Int)