B1.1 · dive — the owner goroutine
Same law, different clothing.
Go states the substrate's first clause as doctrine: do not communicate by sharing memory; share memory by communicating. A goroutine that owns a data structure guarantees sequential access by construction. The substrate translates directly.
Designed counterpart — the manuscript marks the Go store as landing as its own rung. The pure-Go contract package (brandedid) under runtimes/go/ already supplies parse and hash conformance. Source: content/bcs1.1.md · How (Go, as designed).
The design, verbatim
content/bcs1.1.md · How (Go, as designed)One owner goroutine per store holding the map, a channel as the boundary, the namespace gate at the channel's receiving edge, and — because Go maps are unordered — an explicit sorted key slice so byte order keeps supplying mint order. The chapter's snippet, quoted as the manuscript labels it:
// Designed counterpart — lands as its own rung. The gate package exists.
type op struct {
kind byte // put | get | page
id string // 14-byte branded id; gated before the table
value any
reply chan any
}
func propertyStore(ns string, ops <-chan op) {
props := map[string]any{} // owned by this goroutine alone
var keys []string // kept sorted: byte order == mint order
for o := range ops {
// gate via the existing pure-Go contract package (brandedid),
// refuse wrong namespace, then mutate props/keys and reply.
_ = ns
o.reply <- nil
}
}
Illustrative design, not shipped code: the comment in the first line is the manuscript's own label. The course returns to this store when its rung freezes a transcript of its own.
Enforcement differs; the law does not
content/bcs1.1.md · HowThe shapes differ in enforcement, not in law: the BEAM refuses the reach-through at the VM; Go removes the shared reference so there is nothing to reach through. Both put the gate at the one place identities enter.
Where it lands
content/bcs1.1.md · WhereIn the tree, the Go counterpart targets runtimes/go/, where the pure-Go
contract package (brandedid) already supplies parse and hash conformance. The store itself
is designed in the written chapter and lands as its own rung — when that rung freezes its transcript, the
course teaches it the same way this module teaches the Elixir build: line by line, verbatim.
References
sources · relatedSources
- The Go Project — Share Memory By Communicatingthe owner-goroutine pattern; sequential access by construction
- Erlang/OTP — the ets modulethe BEAM half of the comparison — protection levels, term order
- Chassaing — Functional Event Sourcing Deciderthe decide/evolve pattern the manuscript plans Part VIII to rethink on BCS
Related
- B1.1 — The System Substratethe module hub; the Elixir build this design mirrors
- B1 — Ideas Behindthe chapter landing; the Part I arc
- BCS — the course homethe law, the id anatomy, the chapter map