mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Converted sub assembly to smart pointer.
This commit is contained in:
1 parent
e543bd34c0
commit
e51f852504
11 files changed
+133
-87
No files matched your search
@@ -528,8 +528,11 @@ bool ExpressionCompiler::visit(FunctionCall const& _functionCall)
|
||||
// copy the contract's code into memory
|
||||
eth::Assembly const& assembly = m_context.compiledContract(contract);
|
||||
utils().fetchFreeMemoryPointer();
|
||||
// TODO we create a copy here, which is actually what we want.
|
||||
// This should be revisited at the point where we fix
|
||||
// https://github.com/ethereum/solidity/issues/1092
|
||||
// pushes size
|
||||
eth::AssemblyItem subroutine = m_context.addSubroutine(assembly);
|
||||
auto subroutine = m_context.addSubroutine(make_shared<eth::Assembly>(assembly));
|
||||
m_context << Instruction::DUP1 << subroutine;
|
||||
m_context << Instruction::DUP4 << Instruction::CODECOPY;
|
||||
|
||||
|
||||
Reference in new issue
Block a user