a575963da9
Former-commit-id: da6be194a6b1221998fc28233f2503bd61dd9d14
19 lines
309 B
C#
19 lines
309 B
C#
// Compiler options: -r:gtest-161-lib.dll
|
|
|
|
public class App
|
|
{
|
|
public static void Main ()
|
|
{
|
|
string s = apply<int, string> (3, delegate (int x) {
|
|
return x.ToString ();
|
|
});
|
|
|
|
int y = apply<int, int> (3, FP.identity<int>);
|
|
}
|
|
|
|
static U apply<T, U> (T obj, FP.Mapping<T, U> f)
|
|
{
|
|
return f (obj);
|
|
}
|
|
}
|