aboutsummaryrefslogtreecommitdiffstats
path: root/libsolidity/analysis
diff options
context:
space:
mode:
authorAlex Beregszaszi <alex@rtfs.hu>2017-02-09 09:37:53 +0800
committerAlex Beregszaszi <alex@rtfs.hu>2017-02-10 21:29:17 +0800
commitf8461e9e31b96e6656b8dcabd73de2e5176e6fe3 (patch)
tree585f8d6d45b6085c807d69d55a09746898f4b5de /libsolidity/analysis
parentaf8e31b023723bfc6baa224931ef6570cd8d9a32 (diff)
downloaddexon-solidity-f8461e9e31b96e6656b8dcabd73de2e5176e6fe3.tar.gz
dexon-solidity-f8461e9e31b96e6656b8dcabd73de2e5176e6fe3.tar.zst
dexon-solidity-f8461e9e31b96e6656b8dcabd73de2e5176e6fe3.zip
Implement assert as a global function
Diffstat (limited to 'libsolidity/analysis')
-rw-r--r--libsolidity/analysis/GlobalContext.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/libsolidity/analysis/GlobalContext.cpp b/libsolidity/analysis/GlobalContext.cpp
index e46868be..cc418c5e 100644
--- a/libsolidity/analysis/GlobalContext.cpp
+++ b/libsolidity/analysis/GlobalContext.cpp
@@ -65,7 +65,9 @@ m_magicVariables(vector<shared_ptr<MagicVariableDeclaration const>>{make_shared<
make_shared<MagicVariableDeclaration>("ecrecover",
make_shared<FunctionType>(strings{"bytes32", "uint8", "bytes32", "bytes32"}, strings{"address"}, FunctionType::Location::ECRecover)),
make_shared<MagicVariableDeclaration>("ripemd160",
- make_shared<FunctionType>(strings(), strings{"bytes20"}, FunctionType::Location::RIPEMD160, true))})
+ make_shared<FunctionType>(strings(), strings{"bytes20"}, FunctionType::Location::RIPEMD160, true)),
+ make_shared<MagicVariableDeclaration>("assert",
+ make_shared<FunctionType>(strings{"bool"}, strings{}, FunctionType::Location::Assert))})
{
}