Merge pull request #5714 from alexischr/update_bockbuild
[mono.git] / mcs / tests / test-206.cs
1 using System;
2
3 interface I
4 {
5         // int this [int i] { get; }
6         int[] this [params int[] ii] { get; }
7 }
8
9 class X : I {
10         public int this [int i] {
11                 get { return i; }
12         }
13
14         public int[] this [params int[] ii] {
15                 get { return new int[] { this[1], this[2], this[ii.Length] }; }
16         }
17
18         public static void Main ()
19         {
20                 X x = new X ();
21                 Console.WriteLine (x [1]);
22                 int[] r = x [2, 2, 1, 2, 0];
23                 for (int i = 0; i < r.Length; i++)
24                         Console.Write (r [i] + " ");
25                 Console.WriteLine ();
26         }
27 }