public static Primitive.EventloopEntry Readline(Fun2 <Exception, string, Unit> cb) { return(Primitive.RunBlocking <string>( () => { return Console.In.ReadLine(); }, (Exception exn, string result) => { cb.Apply(exn, result); } )); }
public static B Call <A1, A2, B>(this Fun2 <A1, A2, B> f, A1 x1, A2 x2) { return((B)f.Apply(x1, x2)); }