diff options
author | Liana Husikyan <liana@ethdev.com> | 2015-03-04 01:11:10 +0800 |
---|---|---|
committer | Liana Husikyan <liana@ethdev.com> | 2015-03-05 19:08:43 +0800 |
commit | e32bf97e87621bbb1de9623482c84d448e9884ac (patch) | |
tree | 6f78d33c7d4041f95562b35505089d4d5f2608b4 /CompilerContext.h | |
parent | a4d772315d814408c057a9473c2c1fefa351a5b4 (diff) | |
download | dexon-solidity-e32bf97e87621bbb1de9623482c84d448e9884ac.tar.gz dexon-solidity-e32bf97e87621bbb1de9623482c84d448e9884ac.tar.zst dexon-solidity-e32bf97e87621bbb1de9623482c84d448e9884ac.zip |
to include source lines in output stream AssemblyItem's appropriate function is now receiving the map of fileNames to sourceCodes as argument.
Diffstat (limited to 'CompilerContext.h')
-rw-r--r-- | CompilerContext.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/CompilerContext.h b/CompilerContext.h index 301ef146..e42e7c76 100644 --- a/CompilerContext.h +++ b/CompilerContext.h @@ -28,6 +28,7 @@ #include <libevmcore/Assembly.h> #include <libsolidity/ASTForward.h> #include <libsolidity/Types.h> +#include <libdevcore/Common.h> namespace dev { namespace solidity { @@ -118,7 +119,9 @@ public: CompilerContext& operator<<(bytes const& _data); eth::Assembly const& getAssembly() const { return m_asm; } - void streamAssembly(std::ostream& _stream) const { _stream << m_asm; } + /// @arg _sourceCodes is the map of input files to source code strings + void streamAssembly(std::ostream& _stream, StringMap const& _sourceCodes = StringMap()) const { m_asm.streamRLP(_stream, "", _sourceCodes); } + bytes getAssembledBytecode(bool _optimize = false) { return m_asm.optimise(_optimize).assemble(); } /** |