diff options
author | chriseth <chris@ethereum.org> | 2017-12-30 20:47:15 +0800 |
---|---|---|
committer | chriseth <chris@ethereum.org> | 2018-04-12 19:09:37 +0800 |
commit | 8ab7dc036aafd5781118fc16f05df5b0a8a5550e (patch) | |
tree | 6c9a5f1fc1a8855e7655dca0a551b5fc2b54f923 /libsolidity/analysis/NameAndTypeResolver.cpp | |
parent | f00bb4359375cd03e9ff6373b5efa41a37ce2876 (diff) | |
download | dexon-solidity-8ab7dc036aafd5781118fc16f05df5b0a8a5550e.tar dexon-solidity-8ab7dc036aafd5781118fc16f05df5b0a8a5550e.tar.gz dexon-solidity-8ab7dc036aafd5781118fc16f05df5b0a8a5550e.tar.bz2 dexon-solidity-8ab7dc036aafd5781118fc16f05df5b0a8a5550e.tar.lz dexon-solidity-8ab7dc036aafd5781118fc16f05df5b0a8a5550e.tar.xz dexon-solidity-8ab7dc036aafd5781118fc16f05df5b0a8a5550e.tar.zst dexon-solidity-8ab7dc036aafd5781118fc16f05df5b0a8a5550e.zip |
Register overload for ``revert()`` that can receive a reason string.
Diffstat (limited to 'libsolidity/analysis/NameAndTypeResolver.cpp')
-rw-r--r-- | libsolidity/analysis/NameAndTypeResolver.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libsolidity/analysis/NameAndTypeResolver.cpp b/libsolidity/analysis/NameAndTypeResolver.cpp index 5f9e0e99..0a356f04 100644 --- a/libsolidity/analysis/NameAndTypeResolver.cpp +++ b/libsolidity/analysis/NameAndTypeResolver.cpp @@ -47,7 +47,9 @@ NameAndTypeResolver::NameAndTypeResolver( if (!m_scopes[nullptr]) m_scopes[nullptr].reset(new DeclarationContainer()); for (Declaration const* declaration: _globals) - m_scopes[nullptr]->registerDeclaration(*declaration); + { + solAssert(m_scopes[nullptr]->registerDeclaration(*declaration), "Unable to register global declaration."); + } } bool NameAndTypeResolver::registerDeclarations(SourceUnit& _sourceUnit, ASTNode const* _currentScope) |