Commit Graph

12 Commits

Author SHA1 Message Date
4047ccad2f trie: add start key to NodeIterator constructors
The 'step' method is split into two parts, 'peek' and 'push'. peek
returns the next state but doesn't make it current.

The end of iteration was previously tracked by setting 'trie' to nil.
End of iteration is now tracked using the 'iteratorEnd' error, which is
slightly cleaner and requires less code.
2017-04-25 02:14:31 +02:00
a13e920af0 trie: clean up iterator constructors
Make it so each iterator has exactly one public constructor:

- NodeIterators can be created through a method.
- Iterators can be created through NewIterator on any NodeIterator.
2017-04-25 02:14:31 +02:00
b35aa21f9f trie: implement unionIterator (#14312) 2017-04-13 11:14:19 +02:00
555273495b trie: add difference iterator (#3637)
This PR implements a differenceIterator, which allows iterating over trie nodes
that exist in one trie but not in another. This is a prerequisite for most GC
strategies, in order to find obsolete nodes.
2017-02-22 23:49:34 +01:00
35a7dcb162 all: gofmt -w -s 2017-01-06 15:52:03 +01:00
cd791bd855 core, trie: replace state caches with trie journal 2016-09-28 11:27:28 +03:00
5a057a8ded core/state, trie: surface iterator entry hashes 2016-02-16 12:21:08 +02:00
565d9f2306 core, trie: new trie 2015-09-22 22:53:49 +02:00
bfbcfbe4a9 all: fix license headers one more time
I forgot to update one instance of "go-ethereum" in commit 3f047be5a.
2015-07-23 18:35:11 +02:00
3f047be5aa all: update license headers to distiguish GPL/LGPL
All code outside of cmd/ is licensed as LGPL. The headers
now reflect this by calling the whole work "the go-ethereum library".
2015-07-22 18:51:45 +02:00
ea54283b30 all: update license information 2015-07-07 14:12:44 +02:00
db4aaedcbd Moved ptrie => trie. Removed old trie 2015-01-08 11:47:04 +01:00