Earlier quoted context omitted.
Yeah some times godoc comments look crap by necessity
But you don't have to add a docstring. Cases like this are worse than no docstring at all, because it wastes the reader's time. If you add one, at least make the effort to provide some useful information. For example which is more severe: higher or lower numbers.
Show HN: Create a full language server in Go with 3.17 spec support
21–24 of 24 posts
Re: Show HN: Create a full language server in Go with 3.17 spec support
#22The implementation of HoverHandler seems clever... no manual wiring. That's the kind of API design that makes Go's implicit interfaces shine.
I'm curious: How does error recovery work when a handler panics? Does the server keep the connection alive, or does it tear down?
Re: Show HN: Create a full language server in Go with 3.17 spec support
#23I really like the interface-based auto-registration pattern, so elegeant! The implementation of HoverHandler seems clever... no manual wiring. That's the kind of API design that makes Go's implicit interfaces shine. I'm curious: How does error recovery work when a handler panics? Does the server keep the connection alive, or does it tear down?
If its a straight error, then the error response is returned and we're all happy!
If the handler panics, the server crashes, so that's something I'm off to fix now!
Thanks!!!!
Re: Show HN: Create a full language server in Go with 3.17 spec support
#24- Makefile: https://github.com/owenrumney/make-ls
- Goreleaser: https://github.com/owenrumney/goreleaser-ls