diff options
author | Liana Husikyan <liana@ethdev.com> | 2015-04-01 21:41:24 +0800 |
---|---|---|
committer | Liana Husikyan <liana@ethdev.com> | 2015-04-01 21:41:24 +0800 |
commit | e3853ec6d14119052a168c4b5031277c866fd0e0 (patch) | |
tree | 3d025b38fa0959d335983d48ab57a035ac57d03f | |
parent | f730931fc71aa3b1a7985e597ae2d33470b27827 (diff) | |
download | dexon-solidity-e3853ec6d14119052a168c4b5031277c866fd0e0.tar dexon-solidity-e3853ec6d14119052a168c4b5031277c866fd0e0.tar.gz dexon-solidity-e3853ec6d14119052a168c4b5031277c866fd0e0.tar.bz2 dexon-solidity-e3853ec6d14119052a168c4b5031277c866fd0e0.tar.lz dexon-solidity-e3853ec6d14119052a168c4b5031277c866fd0e0.tar.xz dexon-solidity-e3853ec6d14119052a168c4b5031277c866fd0e0.tar.zst dexon-solidity-e3853ec6d14119052a168c4b5031277c866fd0e0.zip |
Update AST.cpp
-rw-r--r-- | AST.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -341,7 +341,7 @@ void FunctionDefinition::checkTypeRequirements() { // todo delete when will be implemented arrays as parameter type in internal functions if (getVisibility() == Visibility::Public && var->getType()->getCategory() == Type::Category::Array) - BOOST_THROW_EXCEPTION(var->createTypeError("Array type is not allowed as parameter for internal functions.")); + BOOST_THROW_EXCEPTION(var->createTypeError("Arrays only implemented for external functions.")); else BOOST_THROW_EXCEPTION(var->createTypeError("Internal type is not allowed for public and external functions.")); } @@ -386,7 +386,7 @@ void VariableDeclaration::checkTypeRequirements() if (m_isStateVariable && !m_type->externalType() && getVisibility() >= Visibility::Public) BOOST_THROW_EXCEPTION(createTypeError("Internal type is not allowed for state variables.")); - auto sharedToExternalTypes = FunctionType(*this).externalType(); // do not distroy the shared pointer. + auto sharedToExternalTypes = FunctionType(*this).externalType(); // do not destroy the shared pointer. auto externalFunctionTypes = dynamic_cast<FunctionType const*>(sharedToExternalTypes.get()); for (auto parameter: externalFunctionTypes->getParameterTypes() + externalFunctionTypes->getReturnParameterTypes()) if (!parameter || !(parameter->externalType())) |