diff options
author | Yoichi Hirai <i@yoichihirai.com> | 2016-09-08 15:47:01 +0800 |
---|---|---|
committer | Yoichi Hirai <i@yoichihirai.com> | 2016-09-10 02:15:13 +0800 |
commit | 4337e70cca58c02de15af258a0efc29062aa0a36 (patch) | |
tree | 4cb0333ed225792929875ab00c935cf71b202ee7 | |
parent | ac7c6ae7d240516b0c530d51645742320634430d (diff) | |
download | dexon-solidity-4337e70cca58c02de15af258a0efc29062aa0a36.tar dexon-solidity-4337e70cca58c02de15af258a0efc29062aa0a36.tar.gz dexon-solidity-4337e70cca58c02de15af258a0efc29062aa0a36.tar.bz2 dexon-solidity-4337e70cca58c02de15af258a0efc29062aa0a36.tar.lz dexon-solidity-4337e70cca58c02de15af258a0efc29062aa0a36.tar.xz dexon-solidity-4337e70cca58c02de15af258a0efc29062aa0a36.tar.zst dexon-solidity-4337e70cca58c02de15af258a0efc29062aa0a36.zip |
Prepare for leaky exceptions
Now toFormalType() reports errors by exceptions, they will be
sometimes leaked to the wider context. This commits adds a catch.
-rw-r--r-- | libsolidity/formal/Why3Translator.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libsolidity/formal/Why3Translator.cpp b/libsolidity/formal/Why3Translator.cpp index 64aa9b4c..f3831b40 100644 --- a/libsolidity/formal/Why3Translator.cpp +++ b/libsolidity/formal/Why3Translator.cpp @@ -36,6 +36,10 @@ bool Why3Translator::process(SourceUnit const& _source) appendPreface(); _source.accept(*this); } + catch (NoFormalType&) + { + solAssert(false, "There is a call to toFormalType() that does not catch NoFormalType exceptions."); + } catch (FatalError& /*_e*/) { solAssert(m_errorOccured, ""); |