4
の単位でレコードに拡張メソッドを追加すると、なぜこの作業を行います。対策
type Money =
{ Amount : decimal } with
member inline m.gotMoney : bool =
m.Amount > 0M
が、これは代わりに、私はerror FS0339: The signature and implementation are not compatible because the type parameter in the class/signature has a different compile-time requirement to the one in the member/implementation
残念ながら、それはです。問題は '0M <_>'は一般的な値とは見なされず、 '0.0 <_>'は一般的な値と見なされます。 – kvb
@kvbこれは「なぜ?質問の一部、ある意味で。それを答えに変換してください。そうすれば、妥当な投票権を得ることができます。 – GregC