diff options
author | chriseth <c@ethdev.com> | 2016-11-11 22:23:50 +0800 |
---|---|---|
committer | chriseth <c@ethdev.com> | 2016-11-16 21:37:19 +0800 |
commit | 7a292c9a05eb38f10f6e619db0805105433fda30 (patch) | |
tree | 5d230d23d78b574c0783f42c41a7a76abdc88506 /test | |
parent | 0335ed4cb476ece63224a96c8ab660116ff08c3a (diff) | |
download | dexon-solidity-7a292c9a05eb38f10f6e619db0805105433fda30.tar.gz dexon-solidity-7a292c9a05eb38f10f6e619db0805105433fda30.tar.zst dexon-solidity-7a292c9a05eb38f10f6e619db0805105433fda30.zip |
Fix parser for function type disambiguity.
Diffstat (limited to 'test')
-rw-r--r-- | test/libsolidity/SolidityParser.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/libsolidity/SolidityParser.cpp b/test/libsolidity/SolidityParser.cpp index 796da782..914dbc30 100644 --- a/test/libsolidity/SolidityParser.cpp +++ b/test/libsolidity/SolidityParser.cpp @@ -1338,6 +1338,17 @@ BOOST_AUTO_TEST_CASE(mapping_and_array_of_functions) BOOST_CHECK(successParse(text)); } +BOOST_AUTO_TEST_CASE(function_type_state_variable) +{ + char const* text = R"( + contract test { + function() x; + function() y = x; + } + )"; + BOOST_CHECK(successParse(text)); +} + BOOST_AUTO_TEST_SUITE_END() |