How to make a function to return really different types in fsharp?
问题 Assume that there is a third-party library written in FSharp, it contains several generic classes, for example as follows: type FirstType<'a> has method DoWork , that accepts: first param of type FirstType<'a> , second param is a function of type ('a -> 'b) DoWork method return type is FirstType<'b> type SecondType<'a> has method DoWork , that accepts: first param of type SecondType<'a> , second param is a function of type ('a -> 'b) DoWork method return type is SecondType<'b> type ThirdType