diff --git a/go/types/initorder.go b/go/types/initorder.go index 2892cfa8..0fd567b2 100644 --- a/go/types/initorder.go +++ b/go/types/initorder.go @@ -137,7 +137,7 @@ func (check *Checker) reportCycle(cycle []*objNode, i int) { obj := cycle[i].obj check.errorf(obj.Pos(), "initialization cycle for %s", obj.Name()) // print cycle - for range cycle { + for _ = range cycle { check.errorf(obj.Pos(), "\t%s refers to", obj.Name()) // secondary error, \t indented i++ if i >= len(cycle) {