示例#1
0
func (ms *memoryRootTracker) UpdateRoot(current, last hash.Hash) bool {
	if last != hash.Hash(*ms) {
		return false
	}

	*ms = memoryRootTracker(current)
	return true
}
示例#2
0
func (ms *memoryRootTracker) Root() hash.Hash {
	return hash.Hash(*ms)
}