x/tools/gopls: show fmt.Stringer representation of a const on mouse over #61838
Labels
FeatureRequest
gopls
Issues related to the Go language server, gopls.
Tools
This label describes issues relating to any tools in the x/tools repository.
Milestone
What did you do?
Moused over
Meters
or any of the other consts.What did you expect to see?
What I want is what is currently done today with the time.Duration type:
I understand this implies a HUGE change to gopls, since it would mean somehow running arbitrary code. This carries some worrysome implications:
I'd understand if this cannot be done today, however I want to start the discussion since this would be a large quality of life improvement for me since I regularly work with SI unit consts to define program behaviour.
I'd also like to refer you all the TinyGo
interp
package which safely evaluates Go code on initialization: https://github.com/tinygo-org/tinygo/tree/release/interp.What did you see instead?
Got very long numbers which are not immediately interpretable, much less when defining other more complex consts with the Distance type.
The text was updated successfully, but these errors were encountered: