aboutsummaryrefslogtreecommitdiffstats
path: root/libsolidity/codegen/Compiler.cpp
diff options
context:
space:
mode:
authorchriseth <c@ethdev.com>2016-11-24 17:32:52 +0800
committerchriseth <c@ethdev.com>2016-12-01 23:03:59 +0800
commit91ecc4533dffbe67fa27adfaff27780ddf69c21a (patch)
tree665bbbe1a0396e56ade492c1a544b1eb1fb4310b /libsolidity/codegen/Compiler.cpp
parent36c6fe2b698b1a05cae954dcee5d9e0fcea85d05 (diff)
downloaddexon-solidity-91ecc4533dffbe67fa27adfaff27780ddf69c21a.tar.gz
dexon-solidity-91ecc4533dffbe67fa27adfaff27780ddf69c21a.tar.zst
dexon-solidity-91ecc4533dffbe67fa27adfaff27780ddf69c21a.zip
Add swarm hash to the end of the bytecode.
Diffstat (limited to 'libsolidity/codegen/Compiler.cpp')
-rw-r--r--libsolidity/codegen/Compiler.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/libsolidity/codegen/Compiler.cpp b/libsolidity/codegen/Compiler.cpp
index 168e9462..b7e0cc64 100644
--- a/libsolidity/codegen/Compiler.cpp
+++ b/libsolidity/codegen/Compiler.cpp
@@ -36,6 +36,7 @@ void Compiler::compileContract(
{
ContractCompiler runtimeCompiler(nullptr, m_runtimeContext, m_optimize);
runtimeCompiler.compileContract(_contract, _contracts);
+ m_runtimeContext.appendAuxiliaryData(_metadataHash.asBytes());
// This might modify m_runtimeContext because it can access runtime functions at
// creation time.
@@ -43,9 +44,6 @@ void Compiler::compileContract(
m_runtimeSub = creationCompiler.compileConstructor(_contract, _contracts);
m_context.optimise(m_optimize, m_optimizeRuns);
-
- solAssert(m_runtimeSub != size_t(-1), "");
- m_context.injectMetadataHashIntoSub(m_runtimeSub, _metadataHash);
}
void Compiler::compileClone(