- Sort Score
- Result 10 results
- Languages All
Results 1 - 1 of 1 for TestNoRaceChanReadWriteAsync (0.38 sec)
-
src/runtime/race/testdata/chan_test.go
}() go func() { c2 <- 10 }() x := 0 go func() { c1 <- x // read of x races with... done <- true }() x = <-c2 // ... write to x here <-done } func TestNoRaceChanReadWriteAsync(t *testing.T) { done := make(chan bool) c1 := make(chan int, 10) x := 0 go func() { c1 <- x // read of x does not race with... done <- true }() x = <-c1 // ... write to x here
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Jul 18 19:55:29 UTC 2023 - 11K bytes - Viewed (0)