aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--AST.cpp14
-rwxr-xr-xAST.h3
-rw-r--r--Types.cpp2
-rw-r--r--Types.h2
4 files changed, 3 insertions, 18 deletions
diff --git a/AST.cpp b/AST.cpp
index ca76d023..38adebf9 100644
--- a/AST.cpp
+++ b/AST.cpp
@@ -519,17 +519,6 @@ void Literal::checkTypeRequirements()
BOOST_THROW_EXCEPTION(createTypeError("Invalid literal value."));
}
-
-bool ParamDescription::operator!=(ParamDescription const& _other) const
-{
- return m_description.first == _other.getName() && m_description.second == _other.getType();
-}
-
-std::ostream& ParamDescription::operator<<(std::ostream& os) const
-{
- return os << m_description.first << ":" << m_description.second;
-}
-
std::string ParamDescription::getName() const
{
return m_description.first;
@@ -540,7 +529,6 @@ std::string ParamDescription::getType() const
return m_description.second;
}
-
ASTPointer<ASTString> FunctionDescription::getDocumentation() const
{
auto function = dynamic_cast<FunctionDefinition const*>(m_description.second);
@@ -575,7 +563,7 @@ vector<ParamDescription> const FunctionDescription::getParameters() const
if (function)
{
vector<ParamDescription> paramsDescription;
- for (auto const& param: function->getParameters())
+ for (auto const& param: function->getReturnParameters())
paramsDescription.push_back(ParamDescription(param->getName(), param->getType()->toString()));
return paramsDescription;
diff --git a/AST.h b/AST.h
index bda06a5d..d9a95e50 100755
--- a/AST.h
+++ b/AST.h
@@ -166,9 +166,6 @@ struct ParamDescription
ParamDescription(std::string const& _name, std::string const& _type):
m_description(_name, _type){}
- bool operator!=(ParamDescription const& _other) const;
- std::ostream& operator<<(std::ostream& os) const;
-
std::string getName() const;
std::string getType() const;
diff --git a/Types.cpp b/Types.cpp
index c5f1a3ae..812271e3 100644
--- a/Types.cpp
+++ b/Types.cpp
@@ -606,7 +606,7 @@ FunctionType::FunctionType(FunctionDefinition const& _function, bool _isInternal
}
FunctionType::FunctionType(VariableDeclaration const& _varDecl):
- m_location(Location::INTERNAL)
+ m_location(Location::EXTERNAL)
{
TypePointers params;
vector<string> paramNames;
diff --git a/Types.h b/Types.h
index b26157b3..2dbed95f 100644
--- a/Types.h
+++ b/Types.h
@@ -378,7 +378,7 @@ public:
virtual MemberList const& getMembers() const override;
Location const& getLocation() const { return m_location; }
- std::string getCanonicalSignature(std::string const &_name) const;
+ std::string getCanonicalSignature(std::string const& _name) const;
bool gasSet() const { return m_gasSet; }
bool valueSet() const { return m_valueSet; }