solidity/test/libsolidity/syntaxTests/dataLocations/memory_storage_data_location.sol
liangdzou f3cbdadec7 Do not set to ref for explicit conversion and add assertion for array
type conversion. Also, add some test cases for #4901 and #4948.
2018-09-14 08:42:40 +02:00

13 lines
361 B
Solidity

contract C {
int[] x;
function f() public {
int[] storage a = x;
int[] memory b;
a = b;
a = int[](b);
}
}
// ----
// TypeError: (93-94): Type int256[] memory is not implicitly convertible to expected type int256[] storage pointer.
// TypeError: (102-110): Type int256[] memory is not implicitly convertible to expected type int256[] storage pointer.