mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Merge pull request #9918 from ethereum/isStateScopeCheck
Make isStateVariable regular scope check.
This commit is contained in:
@@ -642,6 +642,11 @@ bool VariableDeclaration::hasReferenceOrMappingType() const
|
||||
return type->category() == Type::Category::Mapping || dynamic_cast<ReferenceType const*>(type);
|
||||
}
|
||||
|
||||
bool VariableDeclaration::isStateVariable() const
|
||||
{
|
||||
return dynamic_cast<ContractDefinition const*>(scope());
|
||||
}
|
||||
|
||||
set<VariableDeclaration::Location> VariableDeclaration::allowedDataLocations() const
|
||||
{
|
||||
using Location = VariableDeclaration::Location;
|
||||
|
||||
Reference in New Issue
Block a user