Jo Shields a575963da9 Imported Upstream version 3.6.0
Former-commit-id: da6be194a6b1221998fc28233f2503bd61dd9d14
2014-08-13 10:39:27 +01:00

24 lines
634 B
C#

//
// This is a test for bug 78786
// The issue was that the method call would trigger argument compatibility
// checks, and on success it would re-resolve the tree and not every
// expression copes with that gracefully
//
using System.Collections.Generic;
public class Test {
public delegate int TestDel (int a);
public static void Main (string[] args) {
Dictionary<string, TestDel> dict = new Dictionary<string,
TestDel> ();
dict["a"] = delegate (int b) {
return b;
};
System.Console.WriteLine (dict["a"] (2));
}
}