aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLiana Husikyan <liana@ethdev.com>2015-04-27 19:07:25 +0800
committerLiana Husikyan <liana@ethdev.com>2015-04-27 19:08:32 +0800
commit1087d34a665ad2d3595d8a5259d69e8f3d52eebe (patch)
treed544b73e03dd7bedfe0b105f9dea245ce10cdde1
parent88536f90e8403239380c280176250390bab2cd8d (diff)
downloaddexon-solidity-1087d34a665ad2d3595d8a5259d69e8f3d52eebe.tar
dexon-solidity-1087d34a665ad2d3595d8a5259d69e8f3d52eebe.tar.gz
dexon-solidity-1087d34a665ad2d3595d8a5259d69e8f3d52eebe.tar.bz2
dexon-solidity-1087d34a665ad2d3595d8a5259d69e8f3d52eebe.tar.lz
dexon-solidity-1087d34a665ad2d3595d8a5259d69e8f3d52eebe.tar.xz
dexon-solidity-1087d34a665ad2d3595d8a5259d69e8f3d52eebe.tar.zst
dexon-solidity-1087d34a665ad2d3595d8a5259d69e8f3d52eebe.zip
saved returnParameterNames in FunctionType constructor
-rw-r--r--AST.cpp1
-rw-r--r--ExpressionCompiler.cpp1
-rw-r--r--Types.cpp7
-rw-r--r--Types.h3
4 files changed, 10 insertions, 2 deletions
diff --git a/AST.cpp b/AST.cpp
index 83b0adf3..09f98dca 100644
--- a/AST.cpp
+++ b/AST.cpp
@@ -821,6 +821,7 @@ void NewExpression::checkTypeRequirements(TypePointers const*)
parameterTypes,
TypePointers{contractType},
strings(),
+ strings(),
FunctionType::Location::Creation);
}
diff --git a/ExpressionCompiler.cpp b/ExpressionCompiler.cpp
index ae825be1..76d05bd0 100644
--- a/ExpressionCompiler.cpp
+++ b/ExpressionCompiler.cpp
@@ -526,6 +526,7 @@ bool ExpressionCompiler::visit(FunctionCall const& _functionCall)
TypePointers{},
TypePointers{},
strings(),
+ strings(),
Location::External,
false,
true,
diff --git a/Types.cpp b/Types.cpp
index 40b0dba6..7a5b309d 100644
--- a/Types.cpp
+++ b/Types.cpp
@@ -1143,7 +1143,7 @@ FunctionTypePointer FunctionType::externalFunctionType() const
return FunctionTypePointer();
retParamTypes.push_back(type->externalType());
}
- return make_shared<FunctionType>(paramTypes, retParamTypes, m_parameterNames, m_location, m_arbitraryParameters);
+ return make_shared<FunctionType>(paramTypes, retParamTypes, m_parameterNames, m_returnParameterNames, m_location, m_arbitraryParameters);
}
MemberList const& FunctionType::getMembers() const
@@ -1165,6 +1165,7 @@ MemberList const& FunctionType::getMembers() const
parseElementaryTypeVector({"uint"}),
TypePointers{copyAndSetGasOrValue(false, true)},
strings(),
+ strings(),
Location::SetValue,
false,
m_gasSet,
@@ -1180,6 +1181,7 @@ MemberList const& FunctionType::getMembers() const
parseElementaryTypeVector({"uint"}),
TypePointers{copyAndSetGasOrValue(true, false)},
strings(),
+ strings(),
Location::SetGas,
false,
m_gasSet,
@@ -1267,7 +1269,8 @@ TypePointer FunctionType::copyAndSetGasOrValue(bool _setGas, bool _setValue) con
return make_shared<FunctionType>(
m_parameterTypes,
m_returnParameterTypes,
- strings(),
+ m_parameterNames,
+ m_returnParameterNames,
m_location,
m_arbitraryParameters,
m_gasSet || _setGas,
diff --git a/Types.h b/Types.h
index 49dd436d..65a6867d 100644
--- a/Types.h
+++ b/Types.h
@@ -573,6 +573,7 @@ public:
parseElementaryTypeVector(_parameterTypes),
parseElementaryTypeVector(_returnParameterTypes),
strings(),
+ strings(),
_location,
_arbitraryParameters
)
@@ -582,6 +583,7 @@ public:
TypePointers const& _parameterTypes,
TypePointers const& _returnParameterTypes,
strings _parameterNames = strings(),
+ strings _returnParameterNames = strings(),
Location _location = Location::Internal,
bool _arbitraryParameters = false,
bool _gasSet = false,
@@ -590,6 +592,7 @@ public:
m_parameterTypes (_parameterTypes),
m_returnParameterTypes (_returnParameterTypes),
m_parameterNames (_parameterNames),
+ m_returnParameterNames (_returnParameterNames),
m_location (_location),
m_arbitraryParameters (_arbitraryParameters),
m_gasSet (_gasSet),