2 // Tests implicitly typed arrays
8 string[] array
= new [] { "Foo", "Bar", "Baz" }
;
9 foreach (string s
in array
)
13 string[] s1
= new[] { null, "a", default (string) }
;
14 double[] s2
= new[] { 0, 1.0, 2 }
;
16 var a1
= new[] { null, "a", default (string) }
;
17 var a2
= new[] { 0, 1.0, 2 }
;
18 var a3
= new[] { new Test (), null }
;
19 var a4
= new[,] { { 1, 2, 3 }
, { 4, 5, 6 }
};
20 var a5
= new[] { default (object) }
;
21 var a6
= new[] { new [] { 1, 2, 3 }
, new [] { 4, 5, 6 }
};
24 var a7
= new[] { b, 10, b, 999, b }
;