solidity/test/libsolidity/syntaxTests/functionTypes/call_value_on_non_payable_function_type.sol

9 lines
310 B
Solidity
Raw Normal View History

2018-03-16 10:20:06 +00:00
contract C {
function (uint) external returns (uint) x;
function f() public {
x.value(2)();
}
}
2018-03-16 10:33:05 +00:00
// ----
// TypeError: (94-101): Member "value" not found or not visible after argument-dependent lookup in function (uint256) external returns (uint256) - did you forget the "payable" modifier?