[Mono-list] C# language question

Miguel de Icaza miguel@ximian.com
14 Jul 2001 23:45:28 -0400

> I'm working at home without benefits of documentation, and I have a bit of a
> question.  In Java, one can create anonymous classes:
> IFoo quux = new IFoo() {
> 	  public void bar() {
> 		  System.out.println("bar");
> 	  }
> };
> Is it possible to do this in C#?

I do not have the spec handy, but from the grammar it does not look
like classes can be declared anywhere but in the toplevel namespace,
or as part of another class.