From 7d87ccc860dc31c0cd60faf00720e2f30fd37efb Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Sat, 29 Jan 2022 19:07:27 -0500 Subject: all: fix various doc comment formatting nits A run of lines that are indented with any number of spaces or tabs format as a
 block. This commit fixes various doc comments
that format badly according to that (standard) rule.

For example, consider:

	// - List item.
	//   Second line.
	// - Another item.

Because the - lines are unindented, this is actually two paragraphs
separated by a one-line 
 block. This CL rewrites it to:

	//  - List item.
	//    Second line.
	//  - Another item.

Today, that will format as a single 
 block.
In a future release, we hope to format it as a bulleted list.

Various other minor fixes as well, all in preparation for reformatting.

For #51082.

Change-Id: I95cf06040d4186830e571cd50148be3bf8daf189
Reviewed-on: https://go-review.googlesource.com/c/go/+/384257
Trust: Russ Cox 
Run-TryBot: Russ Cox 
Reviewed-by: Ian Lance Taylor 
TryBot-Result: Gopher Robot 
---
 src/runtime/string.go | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

(limited to 'src/runtime/string.go')

diff --git a/src/runtime/string.go b/src/runtime/string.go
index 980a9866e6..eec29075b9 100644
--- a/src/runtime/string.go
+++ b/src/runtime/string.go
@@ -147,10 +147,10 @@ func rawstringtmp(buf *tmpBuf, l int) (s string, b []byte) {
 // and otherwise intrinsified by the compiler.
 //
 // Some internal compiler optimizations use this function.
-// - Used for m[T1{... Tn{..., string(k), ...} ...}] and m[string(k)]
-//   where k is []byte, T1 to Tn is a nesting of struct and array literals.
-// - Used for "<"+string(b)+">" concatenation where b is []byte.
-// - Used for string(b)=="foo" comparison where b is []byte.
+//  - Used for m[T1{... Tn{..., string(k), ...} ...}] and m[string(k)]
+//    where k is []byte, T1 to Tn is a nesting of struct and array literals.
+//  - Used for "<"+string(b)+">" concatenation where b is []byte.
+//  - Used for string(b)=="foo" comparison where b is []byte.
 func slicebytetostringtmp(ptr *byte, n int) (str string) {
 	if raceenabled && n > 0 {
 		racereadrangepc(unsafe.Pointer(ptr),
-- 
cgit v1.3