Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // this works perfectly
- type Example() =
- member this.F(i) = printfn "%d" i
- let inline f (x : ^a) =
- (^a : (member F : int -> unit) (x, 1))
- f (Example())
- // this doesn't but should (function signatures are identical)
- let inline f (x : ^a when ^a : (member F : int -> unit)) =
- x.F(1)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement