aboutsummaryrefslogtreecommitdiffstats
path: root/AST.cpp
diff options
context:
space:
mode:
authorLiana Husikyan <liana@ethdev.com>2015-03-12 21:15:04 +0800
committerLiana Husikyan <liana@ethdev.com>2015-03-16 17:46:46 +0800
commit7d6357ae531f604387fc1f91799fca9a9102e856 (patch)
tree4cb419dd9d6e09ca827dc450287c3d5339b4c082 /AST.cpp
parent67cd3a7180023f613efda64f4f4d2b1bc37990c6 (diff)
downloaddexon-solidity-7d6357ae531f604387fc1f91799fca9a9102e856.tar.gz
dexon-solidity-7d6357ae531f604387fc1f91799fca9a9102e856.tar.zst
dexon-solidity-7d6357ae531f604387fc1f91799fca9a9102e856.zip
- added isPartOfExternalInterface to Declaration
- changed position for the constant specifier. now it goes after type: <type> <constant> <name> = <value> - removed tests for constant functions, checkings for constant function doesn't belong to this story
Diffstat (limited to 'AST.cpp')
-rw-r--r--AST.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/AST.cpp b/AST.cpp
index b0560263..605f5352 100644
--- a/AST.cpp
+++ b/AST.cpp
@@ -189,7 +189,7 @@ vector<pair<FixedHash<4>, FunctionTypePointer>> const& ContractDefinition::getIn
for (ContractDefinition const* contract: getLinearizedBaseContracts())
{
for (ASTPointer<FunctionDefinition> const& f: contract->getDefinedFunctions())
- if (f->isPublic() && !f->isConstructor() && !f->getName().empty() && functionsSeen.count(f->getName()) == 0)
+ if (functionsSeen.count(f->getName()) == 0 && f->isPartOfExternalInterface())
{
functionsSeen.insert(f->getName());
FixedHash<4> hash(dev::sha3(f->getCanonicalSignature()));
@@ -197,7 +197,7 @@ vector<pair<FixedHash<4>, FunctionTypePointer>> const& ContractDefinition::getIn
}
for (ASTPointer<VariableDeclaration> const& v: contract->getStateVariables())
- if (v->isPublic() && functionsSeen.count(v->getName()) == 0 && !v->isConstant())
+ if (functionsSeen.count(v->getName()) == 0 && v->isPartOfExternalInterface())
{
FunctionType ftype(*v);
functionsSeen.insert(v->getName());