mirror of
https://github.com/golang/go
synced 2024-11-06 19:36:30 -07:00
75be6cdcda
Remove the wantSuggestedFixes flag, and run the flagged code by default. Add test cases for suggested fixes. Generate a suggested fix to the assign analysis that suggests removing redundant assignments. Fix the propagation of suggested fixes (using rstambler's code). Change-Id: I342c8e0b75790518f228b00ebd2979d24338be3b Reviewed-on: https://go-review.googlesource.com/c/tools/+/193265 Run-TryBot: Michael Matloob <matloob@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Rebecca Stambler <rstambler@golang.org>
12 lines
124 B
Go
12 lines
124 B
Go
package suggestedfix
|
|
|
|
import (
|
|
"log"
|
|
)
|
|
|
|
func goodbye() {
|
|
s := "hiiiiiii"
|
|
s = s //@suggestedfix("s = s")
|
|
log.Printf(s)
|
|
}
|