From aa644d2adf2a0206508fa6a8f9de0e726dddf77e Mon Sep 17 00:00:00 2001 From: Anderson Queiroz Date: Fri, 23 Aug 2019 10:09:32 +0100 Subject: [PATCH] x/tools/cmd/stringer: document -linecomment in the GoDoc Fixes golang/go#29867 Change-Id: I0328a97c9e2ee4b42a0b0d2b9948bf69a6ee3322 Reviewed-on: https://go-review.googlesource.com/c/tools/+/191309 Reviewed-by: Rob Pike --- cmd/stringer/stringer.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/cmd/stringer/stringer.go b/cmd/stringer/stringer.go index 4b7049a354..0d0692be08 100644 --- a/cmd/stringer/stringer.go +++ b/cmd/stringer/stringer.go @@ -56,6 +56,12 @@ // where t is the lower-cased name of the first type listed. It can be overridden // with the -output flag. // +// The -linecomment flag tells stringer to generate the text of any line comment, trimmed +// of leading spaces, instead of the constant name. For instance, if the constants above had a +// Pill prefix, one could write +// PillAspirin // Aspirin +// to suppress it in the output. + package main // import "golang.org/x/tools/cmd/stringer" import (