diff options
author | Gav Wood <i@gavwood.com> | 2014-01-19 21:06:36 +0800 |
---|---|---|
committer | Gav Wood <i@gavwood.com> | 2014-01-19 21:06:36 +0800 |
commit | 308b3d2d50ad84f2914e80d267a28b034942b8d6 (patch) | |
tree | 7cdaca46160f4651ecc59bf3781eef00856c42e7 /main.cpp | |
parent | 06e7cb9a39722c0e1d2f1de561f5d272188790e4 (diff) | |
download | dexon-solidity-308b3d2d50ad84f2914e80d267a28b034942b8d6.tar dexon-solidity-308b3d2d50ad84f2914e80d267a28b034942b8d6.tar.gz dexon-solidity-308b3d2d50ad84f2914e80d267a28b034942b8d6.tar.bz2 dexon-solidity-308b3d2d50ad84f2914e80d267a28b034942b8d6.tar.lz dexon-solidity-308b3d2d50ad84f2914e80d267a28b034942b8d6.tar.xz dexon-solidity-308b3d2d50ad84f2914e80d267a28b034942b8d6.tar.zst dexon-solidity-308b3d2d50ad84f2914e80d267a28b034942b8d6.zip |
Iterators in the TrieDB!
Diffstat (limited to 'main.cpp')
-rw-r--r-- | main.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -119,16 +119,19 @@ int main() BasicMap m; GenericTrieDB<BasicMap> t(&m); t.init(); // initialise as empty tree. + cout << t; cout << m; cout << t.root() << endl; cout << hash256(StringMap()) << endl; t.insert(string("tesz"), string("test")); + cout << t; cout << m; cout << t.root() << endl; cout << hash256({{"test", "test"}}) << endl; t.insert(string("tesa"), string("testy")); + cout << t; cout << m; cout << t.root() << endl; cout << hash256({{"test", "test"}, {"te", "testy"}}) << endl; @@ -152,6 +155,7 @@ int main() t.init(); // initialise as empty tree. t.insert(string("a"), string("A")); t.insert(string("b"), string("B")); + cout << t; cout << m; cout << t.root() << endl; cout << hash256({{"b", "B"}, {"a", "A"}}) << endl; @@ -194,6 +198,7 @@ int main() cout << endl << "-------------------------------" << endl; cout << a << " -> " << b << endl; + cout << d; cout << m; cout << d.root() << endl; cout << hash256(s) << endl; @@ -215,6 +220,7 @@ int main() cout << endl << "-------------------------------" << endl; cout << "X " << a << endl; + cout << d; cout << m; cout << d.root() << endl; cout << hash256(s) << endl; |