solidity/test/libsolidity/syntaxTests/nameAndTypeResolution/231_array_out_of_bound_access.sol

10 lines
197 B
Solidity
Raw Normal View History

contract c {
uint[2] dataArray;
function set5th() public returns (bool) {
dataArray[5] = 2;
return true;
}
}
// ----
// TypeError: (90-102): Out of bounds array access.