Skip to content
This repository has been archived by the owner on Jul 15, 2023. It is now read-only.

Fix signature / hover provider (e.g. for struct fields) #535

Closed
wants to merge 7 commits into from

Conversation

nochso
Copy link
Contributor

@nochso nochso commented Oct 16, 2016

This fixes #440.

guru is used to find the position of any definition instead of godef as it's more reliable.
The definition lines are read straight from source.

Also godoc is no longer used to fetch the documentation, because querying it did not work in all cases.

This is my first time working with TypeScript, so feel free to nitpick. I've tested all I could think of and it consistently provides useful hover information to me.

This removes the usage of the `godoc` command to fetch the
documentation of any element.

Instead the source is inspected for comments above the definition
or on the same line (like struct fields or interface methods).
guru works better for struct funcs.

`guru definition` returns the location in the same format as before
along with a single line definition (signature).
@msftclas
Copy link

Hi @nochso, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution!

In order for us to evaluate and accept your PR, we ask that you sign a contribution license agreement. It's all electronic and will take just minutes. I promise there's no faxing. https://cla.microsoft.com.

TTYL, MSBOT;

@ramya-rao-a
Copy link
Contributor

@nochso Thanks for the PR! Sorry it took so long to review this.

I tried out your changes and though it works for the hover scenario, other features like Goto Definition, Peek Definition and Signature Help are broken.

What your thoughts on #607 ?

@ramya-rao-a
Copy link
Contributor

ramya-rao-a commented Nov 21, 2016

@nochso #622 was used to fix #440 and 5 other issues.
Therefore closing this PR.
Thanks for your PR though and hope to see more from you.
Happy coding!

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

Successfully merging this pull request may close these issues.

Hover info does not show doc string for structs
3 participants