aboutsummaryrefslogtreecommitdiffstats
path: root/liblll/Parser.cpp
diff options
context:
space:
mode:
authorchriseth <chris@ethereum.org>2018-11-14 02:33:35 +0800
committerGitHub <noreply@github.com>2018-11-14 02:33:35 +0800
commit1d4f565a64988a3400847d2655ca24f73f234bc6 (patch)
treecaaa6c26e307513505349b50ca4f2a8a9506752b /liblll/Parser.cpp
parent59dbf8f1085b8b92e8b7eb0ce380cbeb642e97eb (diff)
parent91b6b8a88e76016e0324036cb7a7f9300a1e2439 (diff)
downloaddexon-solidity-1d4f565a64988a3400847d2655ca24f73f234bc6.tar
dexon-solidity-1d4f565a64988a3400847d2655ca24f73f234bc6.tar.gz
dexon-solidity-1d4f565a64988a3400847d2655ca24f73f234bc6.tar.bz2
dexon-solidity-1d4f565a64988a3400847d2655ca24f73f234bc6.tar.lz
dexon-solidity-1d4f565a64988a3400847d2655ca24f73f234bc6.tar.xz
dexon-solidity-1d4f565a64988a3400847d2655ca24f73f234bc6.tar.zst
dexon-solidity-1d4f565a64988a3400847d2655ca24f73f234bc6.zip
Merge pull request #5416 from ethereum/develop
Merge develop into release for 0.5.0
Diffstat (limited to 'liblll/Parser.cpp')
-rw-r--r--liblll/Parser.cpp18
1 files changed, 10 insertions, 8 deletions
diff --git a/liblll/Parser.cpp b/liblll/Parser.cpp
index a3962df4..854aeecc 100644
--- a/liblll/Parser.cpp
+++ b/liblll/Parser.cpp
@@ -33,12 +33,12 @@
using namespace std;
using namespace dev;
-using namespace dev::eth;
+using namespace dev::lll;
namespace qi = boost::spirit::qi;
namespace px = boost::phoenix;
namespace sp = boost::spirit;
-void dev::eth::killBigints(sp::utree const& _this)
+void dev::lll::killBigints(sp::utree const& _this)
{
switch (_this.which())
{
@@ -48,7 +48,7 @@ void dev::eth::killBigints(sp::utree const& _this)
}
}
-void dev::eth::debugOutAST(ostream& _out, sp::utree const& _this)
+void dev::lll::debugOutAST(ostream& _out, sp::utree const& _this)
{
switch (_this.which())
{
@@ -74,7 +74,8 @@ void dev::eth::debugOutAST(ostream& _out, sp::utree const& _this)
}
}
-namespace dev { namespace eth {
+namespace dev {
+namespace lll {
namespace parseTreeLLL_ {
template<unsigned N>
@@ -88,11 +89,11 @@ struct tagNode
}}}
-void dev::eth::parseTreeLLL(string const& _s, sp::utree& o_out)
+void dev::lll::parseTreeLLL(string const& _s, sp::utree& o_out)
{
using qi::standard::space;
using qi::standard::space_type;
- using dev::eth::parseTreeLLL_::tagNode;
+ using dev::lll::parseTreeLLL_::tagNode;
using symbol_type = sp::basic_string<std::string, sp::utree_type::symbol_type>;
using it = string::const_iterator;
@@ -142,12 +143,13 @@ void dev::eth::parseTreeLLL(string const& _s, sp::utree& o_out)
catch (qi::expectation_failure<it> const& e)
{
std::string fragment(e.first, e.last);
- std::string loc = std::to_string(std::distance(s.cbegin(), e.first) - 1);
+ std::string loc = to_string(std::distance(s.cbegin(), e.first) - 1);
std::string reason("Lexer failure at " + loc + ": '" + fragment + "'");
BOOST_THROW_EXCEPTION(ParserException() << errinfo_comment(reason));
}
for (auto i = ret; i != s.cend(); ++i)
- if (!isspace(*i)) {
+ if (!isspace(*i))
+ {
BOOST_THROW_EXCEPTION(ParserException() << errinfo_comment("Non-whitespace left in parser"));
}
}