mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
More testing on new Trie format.
This commit is contained in:
parent
58d10e79be
commit
7a769e3f39
13
main.cpp
13
main.cpp
@ -93,9 +93,20 @@ int main()
|
||||
*/
|
||||
{
|
||||
Trie t;
|
||||
cout << hex << hash256(StringMap({})) << endl;
|
||||
t.insert("dog", "puppy");
|
||||
cout << hex << t.hash256() << endl;
|
||||
cout << RLP(t.rlp()) << endl;
|
||||
}
|
||||
{
|
||||
Trie t;
|
||||
t.insert("bed", "d");
|
||||
t.insert("be", "e");
|
||||
cout << hex << t.hash256() << endl;
|
||||
cout << RLP(t.rlp()) << endl;
|
||||
}
|
||||
{
|
||||
cout << hex << hash256({{"dog", "puppy"}, {"doe", "reindeer"}}) << endl;
|
||||
Trie t;
|
||||
t.insert("dog", "puppy");
|
||||
t.insert("doe", "reindeer");
|
||||
cout << hex << t.hash256() << endl;
|
||||
|
Loading…
Reference in New Issue
Block a user