compiler-design-eth/javali_tests/HW4_nop90/Array/ErrArraySize.javali

10 lines
173 B
Text
Raw Permalink Normal View History

2020-01-15 22:34:57 +01:00
/* Test creating an array with negative length */
class Main {
void main() {
int[] x;
x = new int[-3];
x[0] = 3;
x[1] = 4;
x[2] = 5;
}
}