solidity/test/libsolidity/syntaxTests/array/length/cannot_be_assigned_mapping.sol
2022-04-01 23:41:18 -05:00

9 lines
225 B
Solidity

contract C {
mapping(uint => uint[]) map;
function f() public {
map[0].length = 4;
}
}
// ----
// TypeError 7567: (80-93='map[0].length'): Member "length" is read-only and cannot be used to resize arrays.