From 0b6763ddc15bc9a6311d1378a704f69cd4cbd976 Mon Sep 17 00:00:00 2001 From: Gav Wood Date: Fri, 30 May 2014 15:25:13 +0200 Subject: [PATCH] Repotting, renaming and reorganisation. --- state.cpp | 2 +- trie.cpp | 26 +++++++++++++------------- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/state.cpp b/state.cpp index 262bf6762..92b274ecc 100644 --- a/state.cpp +++ b/state.cpp @@ -38,7 +38,7 @@ int stateTest() Defaults::setDBPath(boost::filesystem::temp_directory_path().string()); - Overlay stateDB = State::openDB(); + OverlayDB stateDB = State::openDB(); BlockChain bc; State s(myMiner.address(), stateDB); diff --git a/trie.cpp b/trie.cpp index 59823f20b..defa87879 100644 --- a/trie.cpp +++ b/trie.cpp @@ -63,8 +63,8 @@ BOOST_AUTO_TEST_CASE(trie_tests) for (unsigned j = 0; j < eth::test::fac((unsigned)ss.size()); ++j) { next_permutation(ss.begin(), ss.end()); - BasicMap m; - GenericTrieDB t(&m); + MemoryDB m; + GenericTrieDB t(&m); t.init(); BOOST_REQUIRE(t.check(true)); for (auto const& k: ss) @@ -91,8 +91,8 @@ BOOST_AUTO_TEST_CASE(moreTrieTests) #if 0 // More tests... { - BasicMap m; - GenericTrieDB t(&m); + MemoryDB m; + GenericTrieDB t(&m); t.init(); // initialise as empty tree. cout << t; cout << m; @@ -125,8 +125,8 @@ BOOST_AUTO_TEST_CASE(moreTrieTests) cout << hash256(StringMap()) << endl; } { - BasicMap m; - GenericTrieDB t(&m); + MemoryDB m; + GenericTrieDB t(&m); t.init(); // initialise as empty tree. t.insert(string("a"), string("A")); t.insert(string("b"), string("B")); @@ -160,8 +160,8 @@ BOOST_AUTO_TEST_CASE(moreTrieTests) } #endif { - BasicMap m; - GenericTrieDB d(&m); + MemoryDB m; + GenericTrieDB d(&m); d.init(); // initialise as empty tree. MemTrie t; StringMap s; @@ -233,10 +233,10 @@ BOOST_AUTO_TEST_CASE(trieStess) { cnote << "Stress-testing Trie..."; { - BasicMap m; - BasicMap dm; + MemoryDB m; + MemoryDB dm; EnforceRefs e(dm, true); - GenericTrieDB d(&dm); + GenericTrieDB d(&dm); d.init(); // initialise as empty tree. MemTrie t; BOOST_REQUIRE(d.check(true)); @@ -267,9 +267,9 @@ BOOST_AUTO_TEST_CASE(trieStess) for (auto i: d) cwarn << i.first.toString() << i.second.toString(); - BasicMap dm2; + MemoryDB dm2; EnforceRefs e2(dm2, true); - GenericTrieDB d2(&dm2); + GenericTrieDB d2(&dm2); d2.init(); // initialise as empty tree. for (auto i: d) d2.insert(i.first, i.second);