aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGav Wood <i@gavwood.com>2014-12-24 18:36:08 +0800
committerGav Wood <i@gavwood.com>2014-12-24 18:36:08 +0800
commitbe5989f134a6aaa6cb50c12ece79a47fc948803b (patch)
treec72399d715735d66b95f79380b0afd4d0e987a18
parentf4eab75fffb9c58e00e5cb114a70e4c4606699c5 (diff)
downloaddexon-solidity-be5989f134a6aaa6cb50c12ece79a47fc948803b.tar.gz
dexon-solidity-be5989f134a6aaa6cb50c12ece79a47fc948803b.tar.zst
dexon-solidity-be5989f134a6aaa6cb50c12ece79a47fc948803b.zip
Implemented 256-long history for PREVHASH, though still optional.
-rw-r--r--solidityExecutionFramework.h2
-rw-r--r--state.cpp2
-rw-r--r--stateOriginal.cpp2
-rw-r--r--vm.cpp2
4 files changed, 4 insertions, 4 deletions
diff --git a/solidityExecutionFramework.h b/solidityExecutionFramework.h
index 91ee7ad6..9f25b372 100644
--- a/solidityExecutionFramework.h
+++ b/solidityExecutionFramework.h
@@ -117,7 +117,7 @@ private:
void sendMessage(bytes const& _data, bool _isCreation, u256 const& _value = 0)
{
m_state.addBalance(m_sender, _value); // just in case
- eth::Executive executive(m_state, 0);
+ eth::Executive executive(m_state, eth::LastHashes(), 0);
eth::Transaction t = _isCreation ? eth::Transaction(_value, m_gasPrice, m_gas, _data, 0, KeyPair::create().sec())
: eth::Transaction(_value, m_gasPrice, m_gas, m_contractAddress, _data, 0, KeyPair::create().sec());
bytes transactionRLP = t.rlp();
diff --git a/state.cpp b/state.cpp
index b1ad8d44..13346822 100644
--- a/state.cpp
+++ b/state.cpp
@@ -62,7 +62,7 @@ void doStateTests(json_spirit::mValue& v, bool _fillin)
try
{
- theState.execute(tx, &output);
+ theState.execute(LastHashes(), tx, &output);
}
catch (Exception const& _e)
{
diff --git a/stateOriginal.cpp b/stateOriginal.cpp
index 8344894f..a49c5506 100644
--- a/stateOriginal.cpp
+++ b/stateOriginal.cpp
@@ -69,7 +69,7 @@ int stateTest()
assert(t.sender() == myMiner.address());
tx = t.rlp();
}
- s.execute(tx);
+ s.execute(bc, tx);
cout << s;
diff --git a/vm.cpp b/vm.cpp
index 920f0582..18bf5797 100644
--- a/vm.cpp
+++ b/vm.cpp
@@ -33,7 +33,7 @@ using namespace dev::eth;
using namespace dev::test;
FakeExtVM::FakeExtVM(eth::BlockInfo const& _previousBlock, eth::BlockInfo const& _currentBlock, unsigned _depth): /// TODO: XXX: remove the default argument & fix.
- ExtVMFace(Address(), Address(), Address(), 0, 1, bytesConstRef(), bytes(), _previousBlock, _currentBlock, _depth) {}
+ ExtVMFace(Address(), Address(), Address(), 0, 1, bytesConstRef(), bytes(), _previousBlock, _currentBlock, LastHashes(), _depth) {}
h160 FakeExtVM::create(u256 _endowment, u256& io_gas, bytesConstRef _init, OnOpFunc const&)
{