mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Merge pull request #6094 from ethereum/fixCompilationErrors
Fix compilation errors
This commit is contained in:
commit
bb9230a6c1
@ -28,7 +28,7 @@ using namespace std;
|
|||||||
using namespace dev;
|
using namespace dev;
|
||||||
using namespace dev::lll;
|
using namespace dev::lll;
|
||||||
|
|
||||||
bytes dev::lll::compileLLL(string const& _src, dev::solidity::EVMVersion _evmVersion, bool _opt, std::vector<std::string>* _errors, ReadCallback const& _readFile)
|
bytes dev::lll::compileLLL(string const& _src, langutil::EVMVersion _evmVersion, bool _opt, std::vector<std::string>* _errors, ReadCallback const& _readFile)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
@ -66,7 +66,7 @@ bytes dev::lll::compileLLL(string const& _src, dev::solidity::EVMVersion _evmVer
|
|||||||
return bytes();
|
return bytes();
|
||||||
}
|
}
|
||||||
|
|
||||||
std::string dev::lll::compileLLLToAsm(std::string const& _src, EVMVersion _evmVersion, bool _opt, std::vector<std::string>* _errors, ReadCallback const& _readFile)
|
std::string dev::lll::compileLLLToAsm(std::string const& _src, langutil::EVMVersion _evmVersion, bool _opt, std::vector<std::string>* _errors, ReadCallback const& _readFile)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
@ -36,8 +36,8 @@ namespace lll
|
|||||||
using ReadCallback = std::function<std::string(std::string const&)>;
|
using ReadCallback = std::function<std::string(std::string const&)>;
|
||||||
|
|
||||||
std::string parseLLL(std::string const& _src);
|
std::string parseLLL(std::string const& _src);
|
||||||
std::string compileLLLToAsm(std::string const& _src, solidity::EVMVersion _evmVersion, bool _opt = true, std::vector<std::string>* _errors = nullptr, ReadCallback const& _readFile = ReadCallback());
|
std::string compileLLLToAsm(std::string const& _src, langutil::EVMVersion _evmVersion, bool _opt = true, std::vector<std::string>* _errors = nullptr, ReadCallback const& _readFile = ReadCallback());
|
||||||
bytes compileLLL(std::string const& _src, solidity::EVMVersion _evmVersion, bool _opt = true, std::vector<std::string>* _errors = nullptr, ReadCallback const& _readFile = ReadCallback());
|
bytes compileLLL(std::string const& _src, langutil::EVMVersion _evmVersion, bool _opt = true, std::vector<std::string>* _errors = nullptr, ReadCallback const& _readFile = ReadCallback());
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,26 +0,0 @@
|
|||||||
/*
|
|
||||||
This file is part of solidity.
|
|
||||||
|
|
||||||
solidity is free software: you can redistribute it and/or modify
|
|
||||||
it under the terms of the GNU General Public License as published by
|
|
||||||
the Free Software Foundation, either version 3 of the License, or
|
|
||||||
(at your option) any later version.
|
|
||||||
|
|
||||||
solidity is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
GNU General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License
|
|
||||||
along with solidity. If not, see <http://www.gnu.org/licenses/>.
|
|
||||||
*/
|
|
||||||
/**
|
|
||||||
* Information generated during analyzer part of inline assembly.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <libyul/AsmAnalysisInfo.h>
|
|
||||||
|
|
||||||
#include <libyul/AsmScope.h>
|
|
||||||
|
|
||||||
#include <ostream>
|
|
||||||
|
|
@ -1,7 +1,6 @@
|
|||||||
add_library(yul
|
add_library(yul
|
||||||
AsmAnalysis.cpp
|
AsmAnalysis.cpp
|
||||||
AsmAnalysis.h
|
AsmAnalysis.h
|
||||||
AsmAnalysisInfo.cpp
|
|
||||||
AsmAnalysisInfo.h
|
AsmAnalysisInfo.h
|
||||||
AsmData.h
|
AsmData.h
|
||||||
AsmDataForward.h
|
AsmDataForward.h
|
||||||
@ -17,7 +16,6 @@ add_library(yul
|
|||||||
AssemblyStack.cpp
|
AssemblyStack.cpp
|
||||||
CompilabilityChecker.cpp
|
CompilabilityChecker.cpp
|
||||||
CompilabilityChecker.h
|
CompilabilityChecker.h
|
||||||
Dialect.cpp
|
|
||||||
Dialect.h
|
Dialect.h
|
||||||
Exceptions.h
|
Exceptions.h
|
||||||
Object.cpp
|
Object.cpp
|
||||||
|
@ -1,29 +0,0 @@
|
|||||||
/*
|
|
||||||
This file is part of solidity.
|
|
||||||
|
|
||||||
solidity is free software: you can redistribute it and/or modify
|
|
||||||
it under the terms of the GNU General Public License as published by
|
|
||||||
the Free Software Foundation, either version 3 of the License, or
|
|
||||||
(at your option) any later version.
|
|
||||||
|
|
||||||
solidity is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
GNU General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License
|
|
||||||
along with solidity. If not, see <http://www.gnu.org/licenses/>.
|
|
||||||
*/
|
|
||||||
/**
|
|
||||||
* Yul dialect.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <libyul/Dialect.h>
|
|
||||||
|
|
||||||
#include <libyul/Object.h>
|
|
||||||
#include <libyul/backends/evm/AbstractAssembly.h>
|
|
||||||
|
|
||||||
#include <map>
|
|
||||||
|
|
||||||
using namespace yul;
|
|
||||||
using namespace std;
|
|
@ -134,7 +134,7 @@ int main(int argc, char** argv)
|
|||||||
}
|
}
|
||||||
else if (mode == Binary || mode == Hex)
|
else if (mode == Binary || mode == Hex)
|
||||||
{
|
{
|
||||||
auto bs = compileLLL(src, EVMVersion{}, optimise ? true : false, &errors, readFileAsString);
|
auto bs = compileLLL(src, langutil::EVMVersion{}, optimise ? true : false, &errors, readFileAsString);
|
||||||
if (mode == Hex)
|
if (mode == Hex)
|
||||||
cout << toHex(bs) << endl;
|
cout << toHex(bs) << endl;
|
||||||
else if (mode == Binary)
|
else if (mode == Binary)
|
||||||
@ -146,7 +146,7 @@ int main(int argc, char** argv)
|
|||||||
}
|
}
|
||||||
else if (mode == Assembly)
|
else if (mode == Assembly)
|
||||||
{
|
{
|
||||||
cout << compileLLLToAsm(src, EVMVersion{}, optimise ? true : false, &errors, readFileAsString) << endl;
|
cout << compileLLLToAsm(src, langutil::EVMVersion{}, optimise ? true : false, &errors, readFileAsString) << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (auto const& i: errors)
|
for (auto const& i: errors)
|
||||||
|
Loading…
Reference in New Issue
Block a user