aboutsummaryrefslogtreecommitdiffstats
path: root/libsolidity/analysis
diff options
context:
space:
mode:
authorchriseth <chris@ethereum.org>2017-05-27 01:30:42 +0800
committerGitHub <noreply@github.com>2017-05-27 01:30:42 +0800
commit788b64ea6181af6e7e364e86d64508c4809ca9b7 (patch)
tree2a136a342d6f8980f96043b0f6ce74828f89fdd6 /libsolidity/analysis
parente022f11cdb752a07b6c0f824f3e4f91233a19359 (diff)
parentfe32531a16322c9528c34cfbd32924b4c24a1f13 (diff)
downloaddexon-solidity-788b64ea6181af6e7e364e86d64508c4809ca9b7.tar
dexon-solidity-788b64ea6181af6e7e364e86d64508c4809ca9b7.tar.gz
dexon-solidity-788b64ea6181af6e7e364e86d64508c4809ca9b7.tar.bz2
dexon-solidity-788b64ea6181af6e7e364e86d64508c4809ca9b7.tar.lz
dexon-solidity-788b64ea6181af6e7e364e86d64508c4809ca9b7.tar.xz
dexon-solidity-788b64ea6181af6e7e364e86d64508c4809ca9b7.tar.zst
dexon-solidity-788b64ea6181af6e7e364e86d64508c4809ca9b7.zip
Merge pull request #2291 from ethereum/evm15
Allow different assembly types and target machines.
Diffstat (limited to 'libsolidity/analysis')
-rw-r--r--libsolidity/analysis/ReferencesResolver.cpp4
-rw-r--r--libsolidity/analysis/TypeChecker.cpp10
2 files changed, 7 insertions, 7 deletions
diff --git a/libsolidity/analysis/ReferencesResolver.cpp b/libsolidity/analysis/ReferencesResolver.cpp
index 9433976a..83ea17c7 100644
--- a/libsolidity/analysis/ReferencesResolver.cpp
+++ b/libsolidity/analysis/ReferencesResolver.cpp
@@ -166,8 +166,8 @@ bool ReferencesResolver::visit(InlineAssembly const& _inlineAssembly)
// The only purpose of this step is to fill the inline assembly annotation with
// external references.
ErrorList errorsIgnored;
- assembly::ExternalIdentifierAccess::Resolver resolver =
- [&](assembly::Identifier const& _identifier, assembly::IdentifierContext) {
+ julia::ExternalIdentifierAccess::Resolver resolver =
+ [&](assembly::Identifier const& _identifier, julia::IdentifierContext) {
auto declarations = m_resolver.nameFromCurrentScope(_identifier.name);
bool isSlot = boost::algorithm::ends_with(_identifier.name, "_slot");
bool isOffset = boost::algorithm::ends_with(_identifier.name, "_offset");
diff --git a/libsolidity/analysis/TypeChecker.cpp b/libsolidity/analysis/TypeChecker.cpp
index 8161a3a1..ad22cc66 100644
--- a/libsolidity/analysis/TypeChecker.cpp
+++ b/libsolidity/analysis/TypeChecker.cpp
@@ -631,9 +631,9 @@ bool TypeChecker::visit(InlineAssembly const& _inlineAssembly)
{
// External references have already been resolved in a prior stage and stored in the annotation.
// We run the resolve step again regardless.
- assembly::ExternalIdentifierAccess::Resolver identifierAccess = [&](
+ julia::ExternalIdentifierAccess::Resolver identifierAccess = [&](
assembly::Identifier const& _identifier,
- assembly::IdentifierContext _context
+ julia::IdentifierContext _context
)
{
auto ref = _inlineAssembly.annotation().externalReferences.find(&_identifier);
@@ -650,7 +650,7 @@ bool TypeChecker::visit(InlineAssembly const& _inlineAssembly)
typeError(_identifier.location, "The suffixes _offset and _slot can only be used on storage variables.");
return size_t(-1);
}
- else if (_context != assembly::IdentifierContext::RValue)
+ else if (_context != julia::IdentifierContext::RValue)
{
typeError(_identifier.location, "Storage variables cannot be assigned to.");
return size_t(-1);
@@ -677,13 +677,13 @@ bool TypeChecker::visit(InlineAssembly const& _inlineAssembly)
return size_t(-1);
}
}
- else if (_context == assembly::IdentifierContext::LValue)
+ else if (_context == julia::IdentifierContext::LValue)
{
typeError(_identifier.location, "Only local variables can be assigned to in inline assembly.");
return size_t(-1);
}
- if (_context == assembly::IdentifierContext::RValue)
+ if (_context == julia::IdentifierContext::RValue)
{
solAssert(!!declaration->type(), "Type of declaration required but not yet determined.");
if (dynamic_cast<FunctionDefinition const*>(declaration))