diff options
author | chriseth <c@ethdev.com> | 2015-06-17 18:01:39 +0800 |
---|---|---|
committer | chriseth <c@ethdev.com> | 2015-06-17 20:25:00 +0800 |
commit | 1ff8dbebab1aa450e6800fd188e21aa7944b898c (patch) | |
tree | 0b1c58115344a07fd4bced57c66c2907258ac21b /AST.cpp | |
parent | 17efc422996979289a9c5aa02959066578b09aa8 (diff) | |
download | dexon-solidity-1ff8dbebab1aa450e6800fd188e21aa7944b898c.tar dexon-solidity-1ff8dbebab1aa450e6800fd188e21aa7944b898c.tar.gz dexon-solidity-1ff8dbebab1aa450e6800fd188e21aa7944b898c.tar.bz2 dexon-solidity-1ff8dbebab1aa450e6800fd188e21aa7944b898c.tar.lz dexon-solidity-1ff8dbebab1aa450e6800fd188e21aa7944b898c.tar.xz dexon-solidity-1ff8dbebab1aa450e6800fd188e21aa7944b898c.tar.zst dexon-solidity-1ff8dbebab1aa450e6800fd188e21aa7944b898c.zip |
Accessors for strings.
Diffstat (limited to 'AST.cpp')
-rw-r--r-- | AST.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
@@ -919,7 +919,7 @@ void MemberAccess::checkTypeRequirements(TypePointers const* _argumentTypes) { auto const& arrayType(dynamic_cast<ArrayType const&>(type)); m_isLValue = (*m_memberName == "length" && - arrayType.location() != ReferenceType::Location::CallData && arrayType.isDynamicallySized()); + arrayType.location() != DataLocation::CallData && arrayType.isDynamicallySized()); } else m_isLValue = false; @@ -942,7 +942,7 @@ void IndexAccess::checkTypeRequirements(TypePointers const*) m_type = make_shared<FixedBytesType>(1); else m_type = type.getBaseType(); - m_isLValue = type.location() != ReferenceType::Location::CallData; + m_isLValue = type.location() != DataLocation::CallData; break; } case Type::Category::Mapping: @@ -959,7 +959,7 @@ void IndexAccess::checkTypeRequirements(TypePointers const*) { TypeType const& type = dynamic_cast<TypeType const&>(*m_base->getType()); if (!m_index) - m_type = make_shared<TypeType>(make_shared<ArrayType>(ReferenceType::Location::Memory, type.getActualType())); + m_type = make_shared<TypeType>(make_shared<ArrayType>(DataLocation::Memory, type.getActualType())); else { m_index->checkTypeRequirements(nullptr); @@ -967,7 +967,9 @@ void IndexAccess::checkTypeRequirements(TypePointers const*) if (!length) BOOST_THROW_EXCEPTION(m_index->createTypeError("Integer constant expected.")); m_type = make_shared<TypeType>(make_shared<ArrayType>( - ReferenceType::Location::Memory, type.getActualType(), length->literalValue(nullptr))); + DataLocation::Memory, type.getActualType(), + length->literalValue(nullptr) + )); } break; } |