mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Add syntax test for `address.staticcall.value
`.
This commit is contained in:
parent
ed5265598b
commit
a34735016c
@ -449,6 +449,21 @@ BOOST_AUTO_TEST_CASE(address_staticcall)
|
|||||||
CHECK_ERROR(sourceCode, TypeError, "\"staticcall\" is not supported by the VM version.");
|
CHECK_ERROR(sourceCode, TypeError, "\"staticcall\" is not supported by the VM version.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
BOOST_AUTO_TEST_CASE(address_staticcall_value)
|
||||||
|
{
|
||||||
|
if (dev::test::Options::get().evmVersion().hasStaticCall())
|
||||||
|
{
|
||||||
|
char const* sourceCode = R"(
|
||||||
|
contract C {
|
||||||
|
function f() public view {
|
||||||
|
address(0x4242).staticcall.value;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
)";
|
||||||
|
CHECK_ERROR(sourceCode, TypeError, "Member \"value\" not found or not visible after argument-dependent lookup");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
BOOST_AUTO_TEST_SUITE_END()
|
BOOST_AUTO_TEST_SUITE_END()
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user