Does F# documentation have a way to search for functions by their types?
Posted
by Nathan Sanders
on Stack Overflow
See other posts from Stack Overflow
or by Nathan Sanders
Published on 2010-02-12T17:26:04Z
Indexed on
2010/06/03
14:24 UTC
Read the original article
Hit count: 236
Say I want to know if F# has a library function of type
('T -> bool) -> 'T list -> int
ie, something that counts how many items of a list that a function returns true for. (or returns the index of the first item that returns true)
I used to use the big list at the MSR site for F# before the documentation on MSDN was ready. I could just search the page for the above text because the types were listed. But now the MSDN documentation only lists types on the individual pages--the module page is a mush of descriptive text. Google kinda-sorta works, but it can't help with
// compatible interfaces
('T -> bool) -> Seq<'T> -> int
// argument-swaps
Seq<'T> -> ('T -> bool) -> int
// type-variable names
('a -> bool) -> Seq<'a> -> int
// wrappers
('a -> bool) -> 'a list -> option<int>
// uncurried versions
('T -> bool) * 'T list -> int
// .NET generic syntax
('T -> bool) -> List<'T> -> int
// methods
List<'T> member : ('T -> bool) -> int
Haskell has a standalone program for this called Hoogle. Does F# have an equivalent, like Fing or something?
© Stack Overflow or respective owner