aboutsummaryrefslogtreecommitdiffstats
path: root/common/bytes.go
diff options
context:
space:
mode:
authorJeffrey Wilcke <jeffrey@ethereum.org>2016-02-24 19:57:57 +0800
committerJeffrey Wilcke <jeffrey@ethereum.org>2016-02-24 19:57:57 +0800
commit483feb0d3f015f103f80dbaf2aca9a130f5d964c (patch)
tree8137bf41be9b84bc6797ec55c861332b2efc3ab1 /common/bytes.go
parent1415669ac31cf8f06d107e06681b95c2b5e1c040 (diff)
parent139f6a0f4c1b3358a92bdfb5637878b2c97eba78 (diff)
downloadgo-tangerine-483feb0d3f015f103f80dbaf2aca9a130f5d964c.tar.gz
go-tangerine-483feb0d3f015f103f80dbaf2aca9a130f5d964c.tar.zst
go-tangerine-483feb0d3f015f103f80dbaf2aca9a130f5d964c.zip
Merge pull request #2242 from jimenezrick/upstream-crypto
Closes #2241: Use Keccak-256 from golang.org/x/crypto/sha3 and mention explicitly
Diffstat (limited to 'common/bytes.go')
-rw-r--r--common/bytes.go18
1 files changed, 0 insertions, 18 deletions
diff --git a/common/bytes.go b/common/bytes.go
index ba6987a9e..4fb016a97 100644
--- a/common/bytes.go
+++ b/common/bytes.go
@@ -48,22 +48,6 @@ func FromHex(s string) []byte {
return nil
}
-type Bytes []byte
-
-func (self Bytes) String() string {
- return string(self)
-}
-
-func DeleteFromByteSlice(s [][]byte, hash []byte) [][]byte {
- for i, h := range s {
- if bytes.Compare(h, hash) == 0 {
- return append(s[:i:i], s[i+1:]...)
- }
- }
-
- return s
-}
-
// Number to bytes
//
// Returns the number in bytes with the specified base
@@ -154,7 +138,6 @@ func Hex2Bytes(str string) []byte {
}
func Hex2BytesFixed(str string, flen int) []byte {
-
h, _ := hex.DecodeString(str)
if len(h) == flen {
return h
@@ -167,7 +150,6 @@ func Hex2BytesFixed(str string, flen int) []byte {
return hh
}
}
-
}
func StringToByteFunc(str string, cb func(str string) []byte) (ret []byte) {