This repository has been archived by the owner on Apr 7, 2024. It is now read-only.
forked from golang/tools
-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
gopls/internal/golang: hover: show size/offset info
This change causes Hover to report size information for types and struct fields when hovering over the declaring identifier, plus offset information for struct fields. Some tests needed tweaks to make them CPU-independent, or to disable them on 32-bit machines. Also, add the first release notes using the new git+gerrit workflow (and backfill a missing item for "View package documentation"). Change-Id: Ibe8ac5937912c3802f3ad79e3d9f92ba24eb51de Reviewed-on: https://go-review.googlesource.com/c/tools/+/573076 LUCI-TryBot-Result: Go LUCI <[email protected]> Auto-Submit: Alan Donovan <[email protected]> Reviewed-by: Robert Findley <[email protected]>
- Loading branch information
Showing
13 changed files
with
291 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
This directory contains the draft release notes for each upcoming release. | ||
|
||
Be sure to update the file for the forthcoming release in the same CL | ||
that you add new features or fix noteworthy bugs. | ||
|
||
See https://github.com/golang/tools/releases for all past releases. | ||
|
||
Tip: when reviewing edits to markdown files in Gerrit, to see the | ||
rendered form, click the "Open in Code Search" link (magnifying glass | ||
in blue square) then click "View in > gitiles" (shortcut: `v g`). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
gopls/v0.16.0 | ||
|
||
``` | ||
go install golang.org/x/tools/[email protected] | ||
``` | ||
|
||
## New features | ||
|
||
### Integrated documentation viewer | ||
|
||
Gopls now offers a "View package documentation" code action that opens | ||
a local web page displaying the generated documentation for the | ||
current Go package in a form similar to https://pkg.go.dev. Use it to | ||
preview the marked-up documentation as you prepare API changes, or to | ||
read the documentation for locally edited packages, even ones that | ||
have not yet been saved. Reload the page after an edit to see updated | ||
documentation. | ||
|
||
TODO: demo of VS Code `Source action > View package documentation`. | ||
|
||
Clicking on the source-code link associated with a declaration will | ||
cause your editor to navigate to the declaration. | ||
|
||
TODO: demo of source linking. | ||
TODO: appeal to VS Code users to upvote https://github.com/microsoft/vscode/issues/208093? | ||
|
||
### Hover shows size/offset info | ||
|
||
Hovering over the identifier that declares a type or struct field now | ||
displays the size information for the type, and the offset information | ||
for the field. This information may be helpful when making space | ||
optimizations to your data structures, or when reading assembly code. | ||
|
||
TODO: example hover image. | ||
|
||
## Bugs fixed | ||
|
||
## Thank you to our contributors! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.