Use bloop.Walk instead of BloopWalk for better naming.
Change-Id: I60fb7abf8cdab2c7641c69d1cc06c1d6bef1600b
Reviewed-on: https://go-review.googlesource.com/c/go/+/728960
Reviewed-by: Keith Randall <khr@google.com>
Auto-Submit: Cuong Manh Le <cuong.manhle.vn@gmail.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Junyang Shao <shaojunyang@google.com>
Reviewed-by: Keith Randall <khr@golang.org>
return n
}
-// BloopWalk performs a walk on all functions in the package
+// Walk performs a walk on all functions in the package
// if it imports testing and wrap the results of all qualified
// statements in a runtime.KeepAlive intrinsic call. See package
// doc for more details.
// for b.Loop() {...}
//
// loop's body.
-func BloopWalk(pkg *ir.Package) {
+func Walk(pkg *ir.Package) {
hasTesting := false
for _, i := range pkg.Imports {
if i.Path == "testing" {
}
// Apply bloop markings.
- bloop.BloopWalk(typecheck.Target)
+ bloop.Walk(typecheck.Target)
// Interleaved devirtualization and inlining.
base.Timer.Start("fe", "devirtualize-and-inline")