mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Supply text representation of assembly
This commit is contained in:
parent
f0d213e6b5
commit
ca92bda886
@ -91,7 +91,9 @@ MachineAssemblyObject AssemblyStack::assemble(Machine _machine) const
|
||||
eth::Assembly assembly;
|
||||
assembly::CodeGenerator::assemble(*m_parserResult, *m_analysisInfo, assembly);
|
||||
object.bytecode = make_shared<eth::LinkerObject>(assembly.assemble());
|
||||
/// TODO: fill out text representation
|
||||
ostringstream tmp;
|
||||
assembly.stream(tmp);
|
||||
object.assembly = tmp.str();
|
||||
return object;
|
||||
}
|
||||
case Machine::EVM15:
|
||||
|
@ -1101,6 +1101,10 @@ bool CommandLineInterface::assemble(
|
||||
cout << object.bytecode->toHex() << endl;
|
||||
else
|
||||
cerr << "No binary representation found." << endl;
|
||||
if (!object.assembly.empty())
|
||||
cout << object.assembly << endl;
|
||||
else
|
||||
cerr << "No text representation found." << endl;
|
||||
cout << stack.print() << endl;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user