diff options
Diffstat (limited to 'liblll/Compiler.cpp')
-rw-r--r-- | liblll/Compiler.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/liblll/Compiler.cpp b/liblll/Compiler.cpp index b69675aa..1638f69e 100644 --- a/liblll/Compiler.cpp +++ b/liblll/Compiler.cpp @@ -28,13 +28,14 @@ using namespace std; using namespace dev; using namespace dev::eth; -bytes dev::eth::compileLLL(string const& _src, bool _opt, vector<string>* _errors) + +bytes dev::eth::compileLLL(string const& _src, bool _opt, vector<string>* _errors, ReadCallback const& _readFile) { try { CompilerState cs; cs.populateStandard(); - auto assembly = CodeFragment::compile(_src, cs).assembly(cs); + auto assembly = CodeFragment::compile(_src, cs, _readFile).assembly(cs); if (_opt) assembly = assembly.optimise(true); bytes ret = assembly.assemble().bytecode; @@ -66,13 +67,13 @@ bytes dev::eth::compileLLL(string const& _src, bool _opt, vector<string>* _error return bytes(); } -std::string dev::eth::compileLLLToAsm(std::string const& _src, bool _opt, std::vector<std::string>* _errors) +std::string dev::eth::compileLLLToAsm(std::string const& _src, bool _opt, std::vector<std::string>* _errors, ReadCallback const& _readFile) { try { CompilerState cs; cs.populateStandard(); - auto assembly = CodeFragment::compile(_src, cs).assembly(cs); + auto assembly = CodeFragment::compile(_src, cs, _readFile).assembly(cs); if (_opt) assembly = assembly.optimise(true); string ret = assembly.assemblyString(); |