Oh, sorry, I didn't paste the right code.
On my machine I used this code:
package main
import "fmt"
func below(n uint64 ) {
for n>0 {
fmt.Println(n-1)
n--
}
}
func main() {
below(10);
below(0);
}
The actual code I put into the bugfix site was: func below(n uint64, to chan uint64) {
for n>0 {
to <- n-1
n--
}
close(to)
}
but when writing this comment I went back and didn't modify the for loop to be a while.