aboutsummaryrefslogtreecommitdiffstats
path: root/test/libsolidity/InlineAssembly.cpp
diff options
context:
space:
mode:
authorchriseth <c@ethdev.com>2017-02-01 06:59:41 +0800
committerchriseth <c@ethdev.com>2017-02-16 17:15:22 +0800
commit5d584aded8bcabaafddf2f61692f8663913be603 (patch)
tree4d233a7f3ae77773b3c2d7c58f0fcd39572c5516 /test/libsolidity/InlineAssembly.cpp
parentad751bd3e6f22fadc01d43610ec2e2e008c32f11 (diff)
downloaddexon-solidity-5d584aded8bcabaafddf2f61692f8663913be603.tar.gz
dexon-solidity-5d584aded8bcabaafddf2f61692f8663913be603.tar.zst
dexon-solidity-5d584aded8bcabaafddf2f61692f8663913be603.zip
Parsing function definitions.
Diffstat (limited to 'test/libsolidity/InlineAssembly.cpp')
-rw-r--r--test/libsolidity/InlineAssembly.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/libsolidity/InlineAssembly.cpp b/test/libsolidity/InlineAssembly.cpp
index 8744d96f..5216ac06 100644
--- a/test/libsolidity/InlineAssembly.cpp
+++ b/test/libsolidity/InlineAssembly.cpp
@@ -159,6 +159,16 @@ BOOST_AUTO_TEST_CASE(blocks)
BOOST_CHECK(successParse("{ let x := 7 { let y := 3 } { let z := 2 } }"));
}
+BOOST_AUTO_TEST_CASE(function_definitions)
+{
+ BOOST_CHECK(successParse("{ function f() { } function g(a) -> (x) { } }"));
+}
+
+BOOST_AUTO_TEST_CASE(function_definitions_multiple_args)
+{
+ BOOST_CHECK(successParse("{ function f(a, d) { } function g(a, d) -> (x, y) { } }"));
+}
+
BOOST_AUTO_TEST_SUITE_END()
BOOST_AUTO_TEST_SUITE(Printing)