MCPcopy Create free account
hub / github.com/CPChain/chain / LogsBloom

Function LogsBloom

types/bloom9.go:103–113  ·  view source on GitHub ↗
(logs []*Log)

Source from the content-addressed store, hash-verified

101}
102
103func LogsBloom(logs []*Log) *big.Int {
104 bin := new(big.Int)
105 for _, log := range logs {
106 bin.Or(bin, bloom9(log.Address.Bytes()))
107 for _, b := range log.Topics {
108 bin.Or(bin, bloom9(b[:]))
109 }
110 }
111
112 return bin
113}
114
115func bloom9(b []byte) *big.Int {
116 b = crypto.Keccak256(b[:])

Callers 1

CreateBloomFunction · 0.85

Calls 2

bloom9Function · 0.85
BytesMethod · 0.65

Tested by

no test coverage detected