Skip to content

Commit 36f390d

Browse files
committed
all: gofmt
Use gofmt in root directory, then ignore the changes in the testdata directory and fix some formatting issues manually.
1 parent 248c34b commit 36f390d

File tree

5 files changed

+18
-19
lines changed

5 files changed

+18
-19
lines changed

benchmark/parse/parse_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,11 @@ func TestParseLine(t *testing.T) {
5959
// error handling cases
6060
{
6161
line: "BenchPress 100 19.6 ns/op", // non-benchmark
62-
err: true,
62+
err: true,
6363
},
6464
{
6565
line: "BenchmarkEncrypt lots 19.6 ns/op", // non-int iterations
66-
err: true,
66+
err: true,
6767
},
6868
{
6969
line: "BenchmarkBridge 100000000 19.6 smoots", // unknown unit

gopls/internal/coverage/coverage.go

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,13 @@
99
// and a coverage report for all the packages under internal/lsp, accumulated by all the tests
1010
// under gopls.
1111
//
12-
// -o controls where the coverage file is written, defaulting to /tmp/cover.out
13-
// -i coverage-file will generate the report from an existing coverage file
14-
// -v controls verbosity (0: only report coverage, 1: report as each directory is finished,
15-
// 2: report on each test, 3: more details, 4: too much)
16-
// -t tests only tests packages in the given comma-separated list of directories in gopls.
17-
// The names should start with ., as in ./internal/regtest/bench
18-
// -run tests. If set, -run tests is passed on to the go test command.
12+
// -o controls where the coverage file is written, defaulting to /tmp/cover.out
13+
// -i coverage-file will generate the report from an existing coverage file
14+
// -v controls verbosity (0: only report coverage, 1: report as each directory is finished,
15+
// 2: report on each test, 3: more details, 4: too much)
16+
// -t tests only tests packages in the given comma-separated list of directories in gopls.
17+
// The names should start with ., as in ./internal/regtest/bench
18+
// -run tests. If set, -run tests is passed on to the go test command.
1919
//
2020
// Despite gopls' use of goroutines, the counts are almost deterministic.
2121
package main

internal/lsp/diff/lcs/labels.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import (
88
"fmt"
99
)
1010

11-
// For each D, vec[D] has length D+1,
11+
// For each D, vec[D] has length D+1,
1212
// and the label for (D, k) is stored in vec[D][(D+k)/2].
1313
type label struct {
1414
vec [][]int

internal/typeparams/coretype.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -81,13 +81,13 @@ func CoreType(T types.Type) types.Type {
8181
// restrictions may be arbitrarily complex. For example, consider the
8282
// following:
8383
//
84-
// type A interface{ ~string|~[]byte }
84+
// type A interface{ ~string|~[]byte }
8585
//
86-
// type B interface{ int|string }
86+
// type B interface{ int|string }
8787
//
88-
// type C interface { ~string|~int }
88+
// type C interface { ~string|~int }
8989
//
90-
// type T[P interface{ A|B; C }] int
90+
// type T[P interface{ A|B; C }] int
9191
//
9292
// In this example, the structural type restriction of P is ~string|int: A|B
9393
// expands to ~string|~[]byte|int|string, which reduces to ~string|~[]byte|int,

internal/typeparams/typeterm.go

Lines changed: 4 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)