Commit 49e75ef2 authored by uxrog's avatar uxrog
Browse files

Merge branch 'syntax/multi-dimensional-array' into 'master'

Add test for multi dimensional arrays

See merge request !21
parents 7f44cdbc 7368d945
Pipeline #174626 canceled with stage
class Foo {
public static void main(String[] args) {
/* An array with a size in the first brackets is valid */
int[][][][] array = new int[20][][][];
/* The expression is not checked for validity */
int[][][][] array = new int[a || b || c && d > true < null][][][];
/* This should parse as an array access and be valid */
int array = new int[20][4];
int array = (new int[20])[4];
/* Array dimension is not checked */
int array = new int[20][4][true][null];
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment