aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Pratt <mpratt@google.com>2025-07-22 11:17:06 -0400
committerGopher Robot <gobot@golang.org>2025-07-22 09:16:26 -0700
commit4ed9943b264170b11af375f9cc82807516578c77 (patch)
tree65034a42b2a146092b19c96f191771dac8f71ed2
parent1aaf7422f1c4b6a5c3d942d14e06a9ae41595ec8 (diff)
downloadgo-4ed9943b264170b11af375f9cc82807516578c77.tar.xz
all: go fmt
Change-Id: I6a6a636c341d4ba3518be7f6806093bbdff11c88 Reviewed-on: https://go-review.googlesource.com/c/go/+/689535 LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Auto-Submit: Michael Pratt <mpratt@google.com> Reviewed-by: Michael Knyszek <mknyszek@google.com>
-rw-r--r--src/internal/cgrouptest/cgrouptest_linux.go2
-rw-r--r--src/internal/runtime/strconv/atoi.go1
-rw-r--r--src/internal/runtime/strconv/atoi_test.go1
-rw-r--r--src/runtime/debug.go8
-rw-r--r--src/unicode/utf8/utf8.go4
5 files changed, 7 insertions, 9 deletions
diff --git a/src/internal/cgrouptest/cgrouptest_linux.go b/src/internal/cgrouptest/cgrouptest_linux.go
index f23c37a705..8437f992f7 100644
--- a/src/internal/cgrouptest/cgrouptest_linux.go
+++ b/src/internal/cgrouptest/cgrouptest_linux.go
@@ -114,7 +114,7 @@ func findCurrent(t *testing.T) (string, string) {
if ver != cgroup.V2 {
t.Skipf("cgroup: running on cgroup v%d want v2", ver)
}
- rel := string(buf[1:n]) // The returned path always starts with /, skip it.
+ rel := string(buf[1:n]) // The returned path always starts with /, skip it.
rel = filepath.Join(".", rel) // Make sure this isn't empty string at root.
return mount, rel
}
diff --git a/src/internal/runtime/strconv/atoi.go b/src/internal/runtime/strconv/atoi.go
index 87b3faf6d5..0308757c6f 100644
--- a/src/internal/runtime/strconv/atoi.go
+++ b/src/internal/runtime/strconv/atoi.go
@@ -73,4 +73,3 @@ func Atoi32(s string) (int32, bool) {
}
return 0, false
}
-
diff --git a/src/internal/runtime/strconv/atoi_test.go b/src/internal/runtime/strconv/atoi_test.go
index 49cd6f160a..71a8030b1d 100644
--- a/src/internal/runtime/strconv/atoi_test.go
+++ b/src/internal/runtime/strconv/atoi_test.go
@@ -102,4 +102,3 @@ func TestAtoi32(t *testing.T) {
}
}
}
-
diff --git a/src/runtime/debug.go b/src/runtime/debug.go
index 206cf39f02..dacadd2721 100644
--- a/src/runtime/debug.go
+++ b/src/runtime/debug.go
@@ -19,10 +19,10 @@ import (
// GOMAXPROCS defaults to that value.
//
// Otherwise, the Go runtime selects an appropriate default value from a combination of
-// - the number of logical CPUs on the machine,
-// - the process’s CPU affinity mask,
-// - and, on Linux, the process’s average CPU throughput limit based on cgroup CPU
-// quota, if any.
+// - the number of logical CPUs on the machine,
+// - the process’s CPU affinity mask,
+// - and, on Linux, the process’s average CPU throughput limit based on cgroup CPU
+// quota, if any.
//
// If GODEBUG=containermaxprocs=0 is set and GOMAXPROCS is not set by the
// environment variable, then GOMAXPROCS instead defaults to the value of
diff --git a/src/unicode/utf8/utf8.go b/src/unicode/utf8/utf8.go
index 82fa7c0d4d..3be2f15e8a 100644
--- a/src/unicode/utf8/utf8.go
+++ b/src/unicode/utf8/utf8.go
@@ -263,7 +263,7 @@ func DecodeLastRune(p []byte) (r rune, size int) {
// guard against O(n^2) behavior when traversing
// backwards through strings with long sequences of
// invalid UTF-8.
- lim := max(end - UTFMax, 0)
+ lim := max(end-UTFMax, 0)
for start--; start >= lim; start-- {
if RuneStart(p[start]) {
break
@@ -300,7 +300,7 @@ func DecodeLastRuneInString(s string) (r rune, size int) {
// guard against O(n^2) behavior when traversing
// backwards through strings with long sequences of
// invalid UTF-8.
- lim := max(end - UTFMax, 0)
+ lim := max(end-UTFMax, 0)
for start--; start >= lim; start-- {
if RuneStart(s[start]) {
break