Skip to content

Commit

Permalink
cmd/dist: do not rewrite "any" -> "interface{}"
Browse files Browse the repository at this point in the history
Since go1.22, generic can now be used when building bootstrap toolchain.

Updates #54265
Updates #64751

Change-Id: I93209fc23c92114d37ef36787ea2b520de3ed89d
Reviewed-on: https://go-review.googlesource.com/c/go/+/609915
LUCI-TryBot-Result: Go LUCI <[email protected]>
Auto-Submit: Cuong Manh Le <[email protected]>
Reviewed-by: Dmitri Shuralyov <[email protected]>
Reviewed-by: Ian Lance Taylor <[email protected]>
  • Loading branch information
cuonglm authored and gopherbot committed Aug 30, 2024
1 parent 4448313 commit 88dee90
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions src/cmd/dist/buildtool.go
Original file line number Diff line number Diff line change
Expand Up @@ -312,9 +312,6 @@ var (

func bootstrapFixImports(srcFile string) string {
text := readfile(srcFile)
if !strings.Contains(srcFile, "/cmd/") && !strings.Contains(srcFile, `\cmd\`) {
text = regexp.MustCompile(`\bany\b`).ReplaceAllString(text, "interface{}")
}
lines := strings.SplitAfter(text, "\n")
inBlock := false
inComment := false
Expand Down

0 comments on commit 88dee90

Please sign in to comment.