Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cs0668.cs « errors « mcs - github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 04408a390d21f2bf6879c5739c771c61e9167230 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// cs0668.cs: Two indexers have different names, they should have the same name across the board.
// Line: 

using System.Runtime.CompilerServices;
class A {
	[IndexerName ("Blah")]
	int this [int a] {
	get { return 1; }
	}
	
	[IndexerName ("Foo")]
	int this [string b] {
	get { return 2; }
	}
	
        public static int Main ()
        {
		int a = 5;
		
		if (!(a is object))
			return 3;

		return 0;
        }
}