solidity/test/libsolidity/semanticTests/array/copy_function_storage_array.sol
2020-03-19 14:42:25 +01:00

19 lines
364 B
Solidity

contract C {
function() internal returns (uint)[] x;
function() internal returns (uint)[] y;
function test() public returns (uint256) {
x = new function() internal returns (uint)[](10);
x[9] = a;
y = x;
return y[9]();
}
function a() public returns (uint256) {
return 7;
}
}
// ----
// test() -> 7