accounts/abi: move U256Bytes to common/math (#21020)

This commit is contained in:
Marius van der Wijden
2020-05-04 14:09:14 +02:00
committed by GitHub
parent e872083d44
commit ab72803e6f
9 changed files with 22 additions and 48 deletions

View File

@ -31,7 +31,6 @@ import (
"unicode"
"github.com/ethereum/go-ethereum/accounts"
"github.com/ethereum/go-ethereum/accounts/abi"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/common/hexutil"
"github.com/ethereum/go-ethereum/common/math"
@ -587,7 +586,7 @@ func (typedData *TypedData) EncodePrimitiveValue(encType string, encValue interf
if err != nil {
return nil, err
}
return abi.U256(b), nil
return math.U256Bytes(b), nil
}
return nil, fmt.Errorf("unrecognized type '%s'", encType)