a575963da9
Former-commit-id: da6be194a6b1221998fc28233f2503bd61dd9d14
28 lines
408 B
C#
28 lines
408 B
C#
|
|
//
|
|
// Lambda expression test overload resolution with parameterless arguments
|
|
//
|
|
|
|
using System;
|
|
delegate string funcs (string s);
|
|
delegate int funci (int i);
|
|
|
|
class X {
|
|
static void Foo (funci fi)
|
|
{
|
|
int res = fi (10);
|
|
Console.WriteLine (res);
|
|
}
|
|
|
|
static void Foo (funcs fs)
|
|
{
|
|
string res = fs ("hello");
|
|
Console.WriteLine (res);
|
|
}
|
|
|
|
public static void Main ()
|
|
{
|
|
Foo (x => x + "dingus");
|
|
}
|
|
}
|