aboutsummaryrefslogtreecommitdiffstats
path: root/libsolidity
diff options
context:
space:
mode:
authorchriseth <chris@ethereum.org>2017-10-05 22:12:21 +0800
committerGitHub <noreply@github.com>2017-10-05 22:12:21 +0800
commitd0fa56a217f50458b128b0a570724cdac0a5ee1a (patch)
tree49ca4270f829ac145b0d335092590d8de8961918 /libsolidity
parent8b26d65b62f54083e1bec02b34994962770b420f (diff)
parent09276cb9d3589493176bc45b2075517c2087d75b (diff)
downloaddexon-solidity-d0fa56a217f50458b128b0a570724cdac0a5ee1a.tar.gz
dexon-solidity-d0fa56a217f50458b128b0a570724cdac0a5ee1a.tar.zst
dexon-solidity-d0fa56a217f50458b128b0a570724cdac0a5ee1a.zip
Merge pull request #2981 from ethereum/no-address-overload
Do not add members of address to contracts in experimental 0.5.0
Diffstat (limited to 'libsolidity')
-rw-r--r--libsolidity/ast/Types.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/libsolidity/ast/Types.cpp b/libsolidity/ast/Types.cpp
index a3cbe50a..ff5195ff 100644
--- a/libsolidity/ast/Types.cpp
+++ b/libsolidity/ast/Types.cpp
@@ -1616,9 +1616,10 @@ string ContractType::canonicalName() const
return m_contract.annotation().canonicalName;
}
-MemberList::MemberMap ContractType::nativeMembers(ContractDefinition const*) const
+MemberList::MemberMap ContractType::nativeMembers(ContractDefinition const* _contract) const
{
MemberList::MemberMap members;
+ solAssert(_contract, "");
if (m_super)
{
// add the most derived of all functions which are visible in derived contracts
@@ -1660,7 +1661,9 @@ MemberList::MemberMap ContractType::nativeMembers(ContractDefinition const*) con
&it.second->declaration()
));
}
- addNonConflictingAddressMembers(members);
+ // In 0.5.0 address members are not populated into the contract.
+ if (!_contract->sourceUnit().annotation().experimentalFeatures.count(ExperimentalFeature::V050))
+ addNonConflictingAddressMembers(members);
return members;
}