Function selector and variable (un)packing.

This commit is contained in:
Christian 2014-10-30 18:15:25 +01:00
parent 877aa91c57
commit 9eb7fd274c

View File

@ -115,9 +115,11 @@ int main(int argc, char** argv)
printer.print(cout); printer.print(cout);
bytes instructions; bytes instructions;
Compiler compiler;
try try
{ {
instructions = Compiler::compile(*ast); compiler.compileContract(*ast);
instructions = compiler.getAssembledBytecode();
} }
catch (CompilerError const& exception) catch (CompilerError const& exception)
{ {
@ -125,7 +127,9 @@ int main(int argc, char** argv)
return -1; return -1;
} }
cout << "EVM assembly: " << endl; cout << "EVM assembly:" << endl;
compiler.streamAssembly(cout);
cout << "Opcodes:" << endl;
cout << eth::disassemble(instructions) << endl; cout << eth::disassemble(instructions) << endl;
cout << "Binary: " << toHex(instructions) << endl; cout << "Binary: " << toHex(instructions) << endl;