Skip to content

Commit bc4befb

Browse files
authored
compliance: add for range channel (#90)
1 parent 7311189 commit bc4befb

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
0
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
package main
2+
3+
func main() {
4+
c := make(chan int, 1)
5+
c <- 0
6+
close(c)
7+
8+
for x := range c {
9+
println(x)
10+
}
11+
}

0 commit comments

Comments
 (0)