Grokking Concurrency in Go
Vote

0% completed

​

The Race Detector

One possible output:

last fetched: https://example.com/b

The program compiles, passes go vet, and prints a sensible line. It also contains a data race, as defined in Data Races: two goroutines write lastURL, and nothing orders the two writes. Careful reading finds this race. A real program, however, has thousands of lines and many goroutines, and careful reading cannot check that much code reliably.

Go ships a tool that finds such races while the program runs

.....

.....

.....

Like the course? Get enrolled and start learning!

Reading Progress

0%


Vote for new content