Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // let inline foreach f (o:^T when ^T :(member Item : int)) =
- let inline foreach f o =
- for i in 0 .. (^T:(member get_Length:int)o) do
- let x = (^T:(member get_Item:int->int->unit)(o,i))
- // x
- // (^T:(member get_Item:'a->unit) o)
- ()
- type Hoge =
- member o.Item
- with get(x:int,y:int) = ()
- and set(x:int,y:int) v = ()
- open System.Reflection
- let t = typeof<Text.StringBuilder>
- for mi in t.GetProperties() do
- // if (string mi).Contains("get") then
- printfn "%A" mi
Add Comment
Please, Sign In to add comment