mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-23 05:06:43 +00:00
triedb: opt storageKey
This commit is contained in:
parent
7d8ccddaac
commit
b0c2755ce3
1 changed files with 2 additions and 2 deletions
|
|
@ -28,8 +28,8 @@ import (
|
|||
// storageKey returns a key for uniquely identifying the storage slot.
|
||||
func storageKey(accountHash common.Hash, slotHash common.Hash) [64]byte {
|
||||
var key [64]byte
|
||||
copy(key[:32], accountHash[:])
|
||||
copy(key[32:], slotHash[:])
|
||||
*(*[32]byte)(key[32:]) = slotHash
|
||||
*(*[32]byte)(key[:32]) = accountHash
|
||||
return key
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue