aboutsummaryrefslogtreecommitdiffstats
path: root/InterfaceHandler.cpp
diff options
context:
space:
mode:
authorLefteris Karapetsas <lefteris@refu.co>2015-01-30 01:44:14 +0800
committerLefteris Karapetsas <lefteris@refu.co>2015-01-30 02:18:50 +0800
commit3701543ae8dd8ffbfd58e5648d45699468f10a55 (patch)
tree7b10e0bbbac6139c6cee92b9ebd040444507a311 /InterfaceHandler.cpp
parent04190798eba7a2996b28aee6d74b1c636f575a02 (diff)
downloaddexon-solidity-3701543ae8dd8ffbfd58e5648d45699468f10a55.tar.gz
dexon-solidity-3701543ae8dd8ffbfd58e5648d45699468f10a55.tar.zst
dexon-solidity-3701543ae8dd8ffbfd58e5648d45699468f10a55.zip
FunctionType now returns const ref for Declaration
Diffstat (limited to 'InterfaceHandler.cpp')
-rw-r--r--InterfaceHandler.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/InterfaceHandler.cpp b/InterfaceHandler.cpp
index 4d3ec4d5..92cd5156 100644
--- a/InterfaceHandler.cpp
+++ b/InterfaceHandler.cpp
@@ -59,9 +59,7 @@ std::unique_ptr<std::string> InterfaceHandler::getABIInterface(ContractDefinitio
}
return params;
};
-
- solAssert(it.second->getDeclaration(), "All function interface types should contain a declaration");
- method["name"] = it.second->getDeclaration()->getName();
+ method["name"] = it.second->getDeclaration().getName();
method["constant"] = it.second->isConstant();
method["inputs"] = populateParameters(it.second->getParameterNames(),
it.second->getParameterTypeNames());
@@ -86,7 +84,7 @@ unique_ptr<string> InterfaceHandler::getABISolidityInterface(ContractDefinition
r += (r.size() ? "," : "(") + _paramTypes[i] + " " + _paramNames[i];
return r.size() ? r + ")" : "()";
};
- ret += "function " + it.second->getDeclaration()->getName() +
+ ret += "function " + it.second->getDeclaration().getName() +
populateParameters(it.second->getParameterNames(), it.second->getParameterTypeNames()) +
(it.second->isConstant() ? "constant " : "");
if (it.second->getReturnParameterTypes().size())