summaryrefslogtreecommitdiff
path: root/mcs/errors/cs0079-2.cs
blob: 3116e51d926ccfbcd5de1329a28595bfa881687b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// CS0079: The event `Foo.Event2' can only appear on the left hand side of `+=' or `-=' operator
// Line: 11

using System;

public class Foo {
	EventHandler event2;

	public Foo ()
	{
		Event2 = null;
	}

	public event EventHandler Event2 {
		add { event2 += value; }
		remove {event2 -= value; }
	}
}