*: modernize codebase with newer syntax / helpers (#4110)

Changes came from running
https://pkg.go.dev/golang.org/x/tools/gopls/internal/analysis/modernize
on the codebase.
This commit is contained in:
Derek Parker
2025-08-29 09:50:08 -04:00
committed by GitHub
parent 95e13db069
commit 61573cffb3
53 changed files with 231 additions and 290 deletions

View File

@ -114,7 +114,7 @@ func TestVariableEvaluation(t *testing.T) {
testcases := []struct {
name string
st reflect.Kind
value interface{}
value any
length, cap int64
childrenlen int
}{
@ -1255,7 +1255,7 @@ func TestIssue1075(t *testing.T) {
withTestProcess("clientdo", t, func(p *proc.Target, grp *proc.TargetGroup, fixture protest.Fixture) {
setFunctionBreakpoint(p, t, "net/http.(*Client).Do")
assertNoError(grp.Continue(), t, "Continue()")
for i := 0; i < 10; i++ {
for i := range 10 {
scope, err := proc.GoroutineScope(p, p.CurrentThread())
assertNoError(err, t, fmt.Sprintf("GoroutineScope (%d)", i))
vars, err := scope.LocalVariables(pnormalLoadConfig)