Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#show_doc directive #179

Open
ivg opened this issue Sep 23, 2016 · 10 comments
Open

#show_doc directive #179

ivg opened this issue Sep 23, 2016 · 10 comments

Comments

@ivg
Copy link

ivg commented Sep 23, 2016

This is a feature request :)

It would be nice to explore API documentation using utop, like in ipython.

@nilsbecker
Copy link

nilsbecker commented Oct 17, 2016

+1. i would propose #doc instead since that is faster to tab-complete: #show_doc is ambiguous with #show.

@hcarty
Copy link
Contributor

hcarty commented Oct 17, 2016

merlin and ocp-index both provide mechanisms for viewing documentation which may be reusable here.

It may also be something worth pushing upstream to ocaml since the other #show toplevel directives come from there.

@rgrinberg
Copy link
Collaborator

Does this accomplish what you want: https://github.com/reynir/ocp-index-top

@nilsbecker
Copy link

the screenshot looks perfect!

@arichiardi
Copy link
Contributor

Doc is quite a nice feature to have, I wonder if I can use it ReasonML as well. OCaml newbie here. Thanks for the nice pointer though!

@kandu
Copy link
Collaborator

kandu commented Jul 26, 2019

What about "#infoof"? #294

@pmetzger
Copy link
Member

BTW, I hadn't read this before, but ocp-index-top (as linked to by @rgrinberg above) looks quite nice!

@kandu
Copy link
Collaborator

kandu commented Jul 27, 2019

I've looked ocp-index-top up. It's nice and I find that the first commit in #294 does the same as what ocp-index-top does. There is a small flaw, ocp-index-top indexes and queries identifiers in the same process of the REPL, it hangs and uses 100% CPU after you #require or #load some other libraries into the REPL and then query some info of the required library.

@pmetzger
Copy link
Member

@kandu So do you see #294 as a full replacement for this? And does @ivg agree?

@kandu
Copy link
Collaborator

kandu commented Jul 29, 2019

I didn't notice that this issue already existed when #294 was submitted.
The new directive shows the info containing name, kind, type and optional doc comment.
Because doc comments are not always presented, to name it as "show_doc" or "doc" may not be so suitable IMHO.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants