solidity/test/libsolidity/syntaxTests/constants/assign_constant_function_value_050.sol
2018-05-09 15:07:47 +02:00

9 lines
214 B
Solidity

pragma experimental "v0.5.0";
contract C {
function () pure returns (uint) x;
uint constant y = x();
}
// ----
// TypeError: (105-108): Initial value for constant variable has to be compile-time constant.