Skip to content

Commit 56067e3

Browse files
adonovangopherbot
authored andcommitted
std: remove unused declarations
One function was unused by mistake, and is now used as intended. Change-Id: I42ae7481c6f794b310bdac656ea525bd882f146e Reviewed-on: https://go-review.googlesource.com/c/go/+/706815 Auto-Submit: Alan Donovan <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]>
1 parent d70ad4e commit 56067e3

File tree

4 files changed

+1
-23
lines changed

4 files changed

+1
-23
lines changed

src/runtime/stack_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,7 @@ func setBig(p *int, x int, b bigBuf) {
290290
func TestDeferPtrsPanic(t *testing.T) {
291291
for i := 0; i < 100; i++ {
292292
c := make(chan int, 1)
293-
go testDeferPtrsGoexit(c, i)
293+
go testDeferPtrsPanic(c, i)
294294
if n := <-c; n != 42 {
295295
t.Fatalf("defer's stack references were not adjusted appropriately (i=%d n=%d)", i, n)
296296
}

src/runtime/string_test.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -388,8 +388,6 @@ func TestString2Slice(t *testing.T) {
388388
}
389389
}
390390

391-
const intSize = 32 << (^uint(0) >> 63)
392-
393391
func TestParseByteCount(t *testing.T) {
394392
for _, test := range []struct {
395393
in string

src/sort/sort_slices_benchmark_test.go

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,6 @@ func makeSortedInts(n int) []int {
3434
return ints
3535
}
3636

37-
func makeReversedInts(n int) []int {
38-
ints := make([]int, n)
39-
for i := 0; i < n; i++ {
40-
ints[i] = n - i
41-
}
42-
return ints
43-
}
44-
4537
func makeSortedStrings(n int) []string {
4638
x := make([]string, n)
4739
for i := 0; i < n; i++ {

src/text/template/parse/lex_test.go

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -578,15 +578,3 @@ func TestPos(t *testing.T) {
578578
}
579579
}
580580
}
581-
582-
// parseLexer is a local version of parse that lets us pass in the lexer instead of building it.
583-
// We expect an error, so the tree set and funcs list are explicitly nil.
584-
func (t *Tree) parseLexer(lex *lexer) (tree *Tree, err error) {
585-
defer t.recover(&err)
586-
t.ParseName = t.Name
587-
t.startParse(nil, lex, map[string]*Tree{})
588-
t.parse()
589-
t.add()
590-
t.stopParse()
591-
return t, nil
592-
}

0 commit comments

Comments
 (0)