10 lines
179 B
Text
10 lines
179 B
Text
/* Test access an array on a null pointer */
|
|
|
|
class Main {
|
|
void main() {
|
|
int[] x;
|
|
x = null;
|
|
|
|
x[1] = 5; //this should throw null pointer exception
|
|
}
|
|
}
|