diff options
author | chriseth <chris@ethereum.org> | 2016-09-07 21:07:41 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-09-07 21:07:41 +0800 |
commit | 5e63e61a9063b3676f610ec80715f1e089807e10 (patch) | |
tree | cd00abdc77ea1e73f213f0dfd067fd9923ae0dec | |
parent | 2e70f6bfd180630d41cfc493975b04f39f5d7ab1 (diff) | |
parent | 2d9c407456a0eb0590a320e9ee22ab6c44fc9799 (diff) | |
download | dexon-solidity-5e63e61a9063b3676f610ec80715f1e089807e10.tar.gz dexon-solidity-5e63e61a9063b3676f610ec80715f1e089807e10.tar.zst dexon-solidity-5e63e61a9063b3676f610ec80715f1e089807e10.zip |
Merge pull request #1033 from ethereum/fix-using-notype
Include assert for selfType on bound functions to avoid crash
-rw-r--r-- | libsolidity/ast/Types.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libsolidity/ast/Types.cpp b/libsolidity/ast/Types.cpp index a0c1626d..4b5f12ce 100644 --- a/libsolidity/ast/Types.cpp +++ b/libsolidity/ast/Types.cpp @@ -2130,7 +2130,8 @@ vector<string> const FunctionType::returnParameterTypeNames(bool _addDataLocatio TypePointer FunctionType::selfType() const { - solAssert(bound(), ""); + solAssert(bound(), "Function is not bound."); + solAssert(m_parameterTypes.size() > 0, "Function has no self type."); return m_parameterTypes.at(0); } |