trie/utils: remove unneeded initialization (#30472)

pull/30739/head
zhiqiangxu 2 weeks ago committed by GitHub
parent 3c7336b0e9
commit 896fc51379
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 6
      trie/utils/verkle.go

@ -156,10 +156,6 @@ func GetTreeKey(address []byte, treeIndex *uint256.Int, subIndex byte) []byte {
func GetTreeKeyWithEvaluatedAddress(evaluated *verkle.Point, treeIndex *uint256.Int, subIndex byte) []byte { func GetTreeKeyWithEvaluatedAddress(evaluated *verkle.Point, treeIndex *uint256.Int, subIndex byte) []byte {
var poly [5]fr.Element var poly [5]fr.Element
poly[0].SetZero()
poly[1].SetZero()
poly[2].SetZero()
// little-endian, 32-byte aligned treeIndex // little-endian, 32-byte aligned treeIndex
var index [32]byte var index [32]byte
for i := 0; i < len(treeIndex); i++ { for i := 0; i < len(treeIndex); i++ {
@ -297,8 +293,6 @@ func evaluateAddressPoint(address []byte) *verkle.Point {
} }
var poly [3]fr.Element var poly [3]fr.Element
poly[0].SetZero()
// 32-byte address, interpreted as two little endian // 32-byte address, interpreted as two little endian
// 16-byte numbers. // 16-byte numbers.
verkle.FromLEBytes(&poly[1], address[:16]) verkle.FromLEBytes(&poly[1], address[:16])

Loading…
Cancel
Save