The name of the function that generated the comment
package main
func Test() {
}
type A struct {
}
func (a A) MyMethod() {
}
There are several ways to trigger:
package main
// Test ...
func Test() {
}
// A ...
type A struct {
}
// MyMethod ...
func (a A) MyMethod() {
}
I don't know much about vimScript, so I can't implement it, sorry.
Creating a comment with just the name of the function leaves a lot to be desired. While it would eliminate golint errors, it wouldn't do so meaningfully and would probably be used simply to silence golint without addressing the value that golint identifies as missing. Do you have any suggestions for how to implement this feature meaningfully?
@bhcleek I mean, only used as a prefix for filling comments, the user will replace "..." with the comment content
It would be an incentive for the user to add comments. Most people would just add the name of the function in the comment to silence the linter anyways, why not make it a breeze. I think this is a necessary feature to have
I'd accept a meaningful snippet to do this if someone wants to submit it, but I'm unlikely to implement this any time soon.
Most helpful comment
Creating a comment with just the name of the function leaves a lot to be desired. While it would eliminate golint errors, it wouldn't do so meaningfully and would probably be used simply to silence golint without addressing the value that golint identifies as missing. Do you have any suggestions for how to implement this feature meaningfully?