F#

1,泛型类

type TimeSeriesQueue<'V,'K when'K: comparison>(getKey :'V ->'K)=let daysInCache =7let cache = ref Map.empty

  member x.Foo()=()

2,泛型类,要求实现接口
type Foo<'a when'a :> IComparable>=member x.Bla =0
posted @ 2015-08-14 13:22  墨梅  阅读(252)  评论(0编辑  收藏  举报