Checking rval(newarray) will not give accurate array size because this
is possible:
int[][][] s = new int[2][][];
s[2] = new int[2][2];