Merge remote-tracking branch 'ethereum/conversion' into conversion
This commit is contained in:
@ -57,6 +57,12 @@ type Message interface {
|
||||
Data() []byte
|
||||
}
|
||||
|
||||
func AddressFromMessage(msg Message) common.Address {
|
||||
from, _ := msg.From()
|
||||
|
||||
return crypto.CreateAddress(from, msg.Nonce())
|
||||
}
|
||||
|
||||
func MessageCreatesContract(msg Message) bool {
|
||||
return msg.To() == nil
|
||||
}
|
||||
|
@ -35,3 +35,7 @@ func (b *Bloom) SetBytes(d []byte) {
|
||||
func (b Bloom) Big() *big.Int {
|
||||
return common.Bytes2Big(b[:])
|
||||
}
|
||||
|
||||
func (b Bloom) Bytes() []byte {
|
||||
return b[:]
|
||||
}
|
||||
|
Reference in New Issue
Block a user