From 47177542f54a29562d99b27554ed991f318c058a Mon Sep 17 00:00:00 2001 From: Lefteris Karapetsas Date: Thu, 26 Feb 2015 12:11:54 +0100 Subject: Add structs to inheritable members --- AST.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'AST.cpp') diff --git a/AST.cpp b/AST.cpp index b61eb011..8c1944f9 100644 --- a/AST.cpp +++ b/AST.cpp @@ -231,6 +231,13 @@ vector> const& ContractDefinition::getInheritableMembers memberSeen.insert(v->getName()); m_inheritableMembers->push_back(v); } + + for (ASTPointer const& s: contract->getDefinedStructs()) + if (s->isPublic() && memberSeen.count(s->getName()) == 0) + { + memberSeen.insert(s->getName()); + m_inheritableMembers->push_back(s); + } } } return *m_inheritableMembers; -- cgit