1
0
mirror of https://github.com/golang/go synced 2024-11-22 10:24:41 -07:00
go/test/prove_invert_loop_with_unused_iterators.go

12 lines
225 B
Go
Raw Normal View History

// errorcheck -0 -d=ssa/prove/debug=1
//go:build amd64
package main
func invert(b func(), n int) {
for i := 0; i < n; i++ { // ERROR "(Inverted loop iteration|Induction variable: limits \[0,\?\), increment 1)"
b()
}
}