diff options
author | chriseth <c@ethdev.com> | 2015-11-27 00:28:44 +0800 |
---|---|---|
committer | chriseth <c@ethdev.com> | 2015-11-27 00:28:44 +0800 |
commit | 4aaa150674d5970f651ab3e95e5b0e2daac0e7e0 (patch) | |
tree | 83159d4b3367d9278ea67d37409fa856c58f11bb /libsolidity/ast/AST.cpp | |
parent | cc2df5f9f2726f92bebe95e2a94afb6ba32c785c (diff) | |
download | dexon-solidity-4aaa150674d5970f651ab3e95e5b0e2daac0e7e0.tar.gz dexon-solidity-4aaa150674d5970f651ab3e95e5b0e2daac0e7e0.tar.zst dexon-solidity-4aaa150674d5970f651ab3e95e5b0e2daac0e7e0.zip |
Convert filter to template function.
Diffstat (limited to 'libsolidity/ast/AST.cpp')
-rw-r--r-- | libsolidity/ast/AST.cpp | 54 |
1 files changed, 0 insertions, 54 deletions
diff --git a/libsolidity/ast/AST.cpp b/libsolidity/ast/AST.cpp index 65535388..6006d441 100644 --- a/libsolidity/ast/AST.cpp +++ b/libsolidity/ast/AST.cpp @@ -89,60 +89,6 @@ FunctionDefinition const* ContractDefinition::fallbackFunction() const return nullptr; } -vector<StructDefinition const*> ContractDefinition::definedStructs() const -{ - vector<StructDefinition const*> ret; - for (auto const& node: m_subNodes) - if (auto v = dynamic_cast<StructDefinition const*>(node.get())) - ret.push_back(v); - return ret; -} - -vector<EnumDefinition const*> ContractDefinition::definedEnums() const -{ - vector<EnumDefinition const*> ret; - for (auto const& node: m_subNodes) - if (auto v = dynamic_cast<EnumDefinition const*>(node.get())) - ret.push_back(v); - return ret; -} - -vector<VariableDeclaration const*> ContractDefinition::stateVariables() const -{ - vector<VariableDeclaration const*> ret; - for (auto const& node: m_subNodes) - if (auto v = dynamic_cast<VariableDeclaration const*>(node.get())) - ret.push_back(v); - return ret; -} - -vector<ModifierDefinition const*> ContractDefinition::functionModifiers() const -{ - vector<ModifierDefinition const*> ret; - for (auto const& node: m_subNodes) - if (auto v = dynamic_cast<ModifierDefinition const*>(node.get())) - ret.push_back(v); - return ret; -} - -vector<FunctionDefinition const*> ContractDefinition::definedFunctions() const -{ - vector<FunctionDefinition const*> ret; - for (auto const& node: m_subNodes) - if (auto v = dynamic_cast<FunctionDefinition const*>(node.get())) - ret.push_back(v); - return ret; -} - -vector<EventDefinition const*> ContractDefinition::events() const -{ - vector<EventDefinition const*> ret; - for (auto const& node: m_subNodes) - if (auto v = dynamic_cast<EventDefinition const*>(node.get())) - ret.push_back(v); - return ret; -} - vector<EventDefinition const*> const& ContractDefinition::interfaceEvents() const { if (!m_interfaceEvents) |