[Haskell-beginners] How to check the help page of a function?
Henk-Jan van Tuyl
hjgtuyl at chello.nl
Sun May 17 14:12:38 UTC 2015
On Sun, 17 May 2015 10:24:42 +0200, Henk-Jan van Tuyl <hjgtuyl at chello.nl>
wrote:
> On Sun, 17 May 2015 01:18:50 +0200, Peng Yu <pengyu.ut at gmail.com> wrote:
>
>> Many other languages have help pages in the command (see help() in
>> python and R). Why haskell doesn't have such a feature?
>
> GHCi has such a command:
> :doc <function name>
I forgot that this is not the default behavior of GHCi; to get this
command, install Hoogle[0][1] and create a file called .ghci in your home
directory, with the line:
:def doc \x -> return $ ":!hoogle --info \"" ++ x ++ "\""
Regards,
Henk-Jan van Tuyl
[0] https://hackage.haskell.org/package/hoogle
[1] https://wiki.haskell.org/Hoogle
--
Folding at home
What if you could share your unused computer power to help find a cure? In
just 5 minutes you can join the world's biggest networked computer and get
us closer sooner. Watch the video.
http://folding.stanford.edu/
http://Van.Tuyl.eu/
http://members.chello.nl/hjgtuyl/tourdemonad.html
Haskell programming
--
More information about the Beginners
mailing list