|
Listing 14-19 extracted from chapter Unsafe code, exceptions, anonymous methods, iterators
Listing 14-18< > Listing 14-20
This listing can be compiled with the command line: csc.exe /target:library Example_14_19.cs Errors: 1 Warnings: 0
Example_14_19.cs
using System;
class Program {
delegate void DelegateType( params int[] arr );
static DelegateType GetMethod() {
// Compilation error: param is not valid in this context.
return delegate( params int[] arr ){ Console.WriteLine("Hello");};
}
}
Copyright Patrick Smacchia 2006 2007
|