Accidentally Concurrent
summary
Claim: nearly every program becomes a concurrent system unless its interfaces prevent hidden channels. Uses message-passing concurrency (channels + spawn) to model mutation as tiny threads, reconstructs a hero/bad‑guys game to show emergent bugs, and demonstrates glitches from unsynchronized streams and how flatMap effectively spawns unbounded subthreads. Builds a simple ref-as-loop and a read-only reference that provably blocks accidental two‑way communication, and maps JavaScript’s event loop and Elm’s guidance onto these concrete primitives.
AI-written summary · about
chapters (18)
- 0:00Introduction
- 1:34Messagepassing concurrency
- 4:11Mutation
- 7:11Syntax
- 7:55Cold State
- 8:44Encapsulation
- 10:16Hierarchy
- 13:53Schedulers
- 16:15Event Loop
- 19:33Reactive Programming
- 20:45Map
- 22:17Glitches
- 24:13Flatmap
- 24:58Loop
- 27:19Hero Bad Guy
- 32:02immutability
- 32:59larger systems
- 34:32Wrapup
related talks
52mConcurrency in Haskell with Streamly
49mThinking in a Highly Concurrent, Mostly-functional Language
33mCommunicating with channels
42mHistory of Concurrency
01h 04mA Pattern Language for Expressing Concurrency in Cpp
30mCracking the Concurrent Mode
25mAsynchrony: Under the Hood
25mFunctional effect and streaming systems in Clojure
