From 09e833b07d1311287f7bd234e56be54d8f0412fa Mon Sep 17 00:00:00 2001 From: Gary Rong Date: Thu, 28 Nov 2024 20:55:54 +0800 Subject: [PATCH] triedb/pathdb: enhance the function description --- triedb/pathdb/states.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/triedb/pathdb/states.go b/triedb/pathdb/states.go index a569aad5b6..656f703838 100644 --- a/triedb/pathdb/states.go +++ b/triedb/pathdb/states.go @@ -258,7 +258,9 @@ func (s *stateSet) merge(other *stateSet) { // // Notably, this operation may result in the set containing more entries after a // revert. For example, if account x did not exist and was created during transition -// w, reverting w will retain an x=nil entry in the set. +// w, reverting w will retain an x=nil entry in the set. And also if account x along +// with its storage slots was deleted in the transition w, reverting w will retain +// a list of additional storage slots with their original value. func (s *stateSet) revertTo(accountOrigin map[common.Hash][]byte, storageOrigin map[common.Hash]map[common.Hash][]byte) { var delta int // size tracking for addrHash, blob := range accountOrigin {