# Ep. 6: Exploring Concurrency Pitfalls: Rust vs. C++ and Go

DevFeed: [Ep. 6: Exploring Concurrency Pitfalls: Rust vs. C++ and Go](<https://devfeed.tech/articles/ep-6-exploring-concurrency-pitfalls-rust-vs-c-and-go-22236.md>)

Original publisher: [Read original article](<https://www.ardanlabs.com/blog/2024/05/exploring-concurrency-pitfalls-rust-vs-c-and-go-ep-6.html>)

Published: 2024-05-20T00:00:00Z

Content type: comparison

Language: en

Sources: [William Kennedy](<https://devfeed.tech/sources/william-kennedy.md>)

Topics: [Concurrency](<https://devfeed.tech/topics/concurrency.md>), [Rust](<https://devfeed.tech/topics/rust.md>), [C++](<https://devfeed.tech/topics/c-plus-plus.md>), [Go Language](<https://devfeed.tech/topics/go-language.md>), [Programming](<https://devfeed.tech/topics/programming.md>), [Error Handling](<https://devfeed.tech/topics/error-handling.md>)

Tags: [atomics](<https://devfeed.tech/tags/atomics.md>), [c-plus-plus](<https://devfeed.tech/tags/c-plus-plus.md>), [concurrency](<https://devfeed.tech/tags/concurrency.md>), [error-handling](<https://devfeed.tech/tags/error-handling.md>), [go](<https://devfeed.tech/tags/go.md>), [indicating-intent](<https://devfeed.tech/tags/indicating-intent.md>), [mutex](<https://devfeed.tech/tags/mutex.md>), [pitfalls](<https://devfeed.tech/tags/pitfalls.md>), [reliable-codebases](<https://devfeed.tech/tags/reliable-codebases.md>), [rust](<https://devfeed.tech/tags/rust.md>), [safety-concern](<https://devfeed.tech/tags/safety-concern.md>), [synchronization](<https://devfeed.tech/tags/synchronization.md>), [threads](<https://devfeed.tech/tags/threads.md>), [type-coercion](<https://devfeed.tech/tags/type-coercion.md>)

## AI overview

This video compares how C++, Go, and Rust address data races in concurrent programs. It discusses unsynchronized shared access, Go's race-detection flag, and Rust's stricter mutability and synchronization rules, along with Rust's null-pointer avoidance and error handling.

## Source excerpt

Introduction: Join Herbert in an insightful discussion on concurrency, where he tackles the complexities of data races and how various programming languages address them: Understand the crucial role of recognizing data races in concurrent programming and their potential impacts. See practical examples illustrating the chaos caused by data races and learn how Rust's compiler prevents such issues, ensuring program stability. Explore Rust's unique features like null pointer avoidance and reliable error handling, which enhance safety and reliability in concurrent programming tasks.