-
-
Notifications
You must be signed in to change notification settings - Fork 389
CodeAction to create Haddock comments #403
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
Comments
What do you imagine it doing? Just inserting |
Well, let's take a function definition. It should create a comment for the overall definition; further, it should create a comment for each argument. I wish Haddock had more expressive markup, because I would quite like to automatically insert a bunch of metadata tags too. |
So you would like a code action to turn:
into the following
That sounds doable although I’m not entirely sure it’s super useful since compared to writing the actual docs, inserting the comments seems trivial. |
Turning
into
and
into
would save a non trivial amount of typing and would be quite convenient, I think. (The underscores are denoting snippet placeholders that the language server can use to jump you to each spot where comments can be added) |
In addition to what @jared-w said, it would also help provide motivation to write docs. Who wants to see a bunch of useless comments? :D |
I think this could be a plugin in hls, @ndmitchell @cocreature what do you think about translate this to hls? |
Definitely agreed - one for HLS. We should move most suggestions that can be implemented as HLS plugins, and don't reflect things already in Ghcide, over to HLS. |
This would be super useful.
The text was updated successfully, but these errors were encountered: