Create contracts.

This commit is contained in:
Christian
2014-12-15 13:05:18 +01:00
parent c858699605
commit 2f64c56ef3
21 changed files with 221 additions and 30 deletions
+13
View File
@@ -310,6 +310,19 @@ MemberList const& ContractType::getMembers() const
return *m_members;
}
shared_ptr<FunctionType const> const& ContractType::getConstructorType() const
{
if (!m_constructorType)
{
FunctionDefinition const* constr = m_contract.getConstructor();
if (constr)
m_constructorType = make_shared<FunctionType const>(*constr);
else
m_constructorType = make_shared<FunctionType const>(TypePointers(), TypePointers());
}
return m_constructorType;
}
unsigned ContractType::getFunctionIndex(string const& _functionName) const
{
unsigned index = 0;