gar*_*kes 2 c# clr f# interface
我使用任何体面的C#接口与我的F#类型有一些问题,所以我在一个项目中有以下C#接口...
//C#
namespace FunctionalInterfacing
{
public interface IFoo
{
string Bar(string a, string b);
}
}
Run Code Online (Sandbox Code Playgroud)
现在我想在F#中编写一个实现它的类型..
#light
module FunctionalInterfacing.Concrete
open FunctionalInterfacing
type public ConcreteType =
interface IFoo with
member this.Bar a b = a
Run Code Online (Sandbox Code Playgroud)
这似乎不起作用,我得到以下错误...
此覆盖对相应的抽象成员采用不同数量的参数
有任何想法吗?
| 归档时间: |
|
| 查看次数: |
256 次 |
| 最近记录: |