mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-03 02:27:48 +00:00
feat: fix typos
This commit is contained in:
Vendored
+6
-6
@@ -158,16 +158,16 @@ func main() {
|
||||
ch = make(chan int, 2)
|
||||
ch <- 1
|
||||
ch <- 2
|
||||
println("non-concurrent channel recieve:", <-ch)
|
||||
println("non-concurrent channel recieve:", <-ch)
|
||||
println("non-concurrent channel receive:", <-ch)
|
||||
println("non-concurrent channel receive:", <-ch)
|
||||
|
||||
// test closing channels with buffered data
|
||||
ch <- 3
|
||||
ch <- 4
|
||||
close(ch)
|
||||
println("closed buffered channel recieve:", <-ch)
|
||||
println("closed buffered channel recieve:", <-ch)
|
||||
println("closed buffered channel recieve:", <-ch)
|
||||
println("closed buffered channel receive:", <-ch)
|
||||
println("closed buffered channel receive:", <-ch)
|
||||
println("closed buffered channel receive:", <-ch)
|
||||
|
||||
// test using buffered channels as regular channels with special properties
|
||||
wg.Add(6)
|
||||
@@ -184,7 +184,7 @@ func main() {
|
||||
for range ch {
|
||||
count++
|
||||
}
|
||||
println("hybrid buffered channel recieve:", count)
|
||||
println("hybrid buffered channel receive:", count)
|
||||
|
||||
// test blocking selects
|
||||
ch = make(chan int)
|
||||
|
||||
Vendored
+6
-6
@@ -26,10 +26,10 @@ select n from chan: 55
|
||||
select n from closed chan: 0
|
||||
select send
|
||||
sum: 235
|
||||
non-concurrent channel recieve: 1
|
||||
non-concurrent channel recieve: 2
|
||||
closed buffered channel recieve: 3
|
||||
closed buffered channel recieve: 4
|
||||
closed buffered channel recieve: 0
|
||||
hybrid buffered channel recieve: 2
|
||||
non-concurrent channel receive: 1
|
||||
non-concurrent channel receive: 2
|
||||
closed buffered channel receive: 3
|
||||
closed buffered channel receive: 4
|
||||
closed buffered channel receive: 0
|
||||
hybrid buffered channel receive: 2
|
||||
blocking select sum: 3
|
||||
|
||||
Reference in New Issue
Block a user