Mo Design Decision Matrix

A living menu of concrete design choices for Mo. Each design axis lists the mainstream options, what each is, exemplar languages, pros and cons in Mo’s specific context, implementation cost, how reversible the choice is, and whether it is recommended.


How to use this document

This document is a decision menu, not a set of pronouncements. Each row in each table maps an option to the strongest case for choosing it — Robert’s stated preference is comparisons that surface tradeoffs rather than crowning universal winners. The Recommended for Mo? column reflects the analysis in mo_synthesis.md and is meant as a defensible default, not a verdict; each recommendation carries a brief rationale so Robert (or a future Mo contributor) can weigh a divergent choice with the reasoning in hand.

Two conventions:

  • Implementation cost is a rough estimate of engineering effort to ship a production-quality implementation, rated Low / Medium / High. It assumes a small team and an existing VM baseline (Mo’s current state).
  • Reversibility rates how hard the choice is to change after Mo has real users. Easy = one edition/deprecation cycle. Medium = several years of migration. Hard = essentially a new language.

The document is designed to be updated in place as decisions solidify. When a choice is locked in, mark the row Chosen and record the RFC number.

The final two sections — the Recommended starting stack for Mo and Provocative alternatives — pick coherent combinations from the tables and describe what a Mo built on that combination would feel like.


1. Core paradigm blend

Every language commits to a paradigm mix, even when it claims to be “multi-paradigm.” Van Roy’s argument that paradigms differ “only in a few concepts” (Van Roy, “Programming Paradigms for Dummies”) means the choice is about which concepts to make cheap and which to make expensive. Mo’s stated direction — pure by default, imperative when declared, structs+traits, ADTs+pattern matching — is a specific mix of five paradigmatic concepts.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
Imperative-firstProgram is a sequence of state mutations on the machineC, Zig, Odin, Jai (Kelley on Zig)Matches Mo’s existing VM; agent can inspect allocation sites; predictable performanceFights the pure-by-default direction; forces effects everywhereLowHardNo — imperative available, not primary
Functional-first (pure)Program is a composition of pure functions; effects declaredHaskell, Elm, Roc, PureScript (Peyton Jones “Hair Shirt”; Roc “Fast”)Purity enables local reasoning; effect discipline emerges naturally; annotation cost paid by agentHistorical human resistance; need for effect handlers or monads for real codeMediumHardYes — pure-by-default is Mo’s central bet
Actor-firstProgram is a network of isolated processes exchanging messagesErlang, Elixir, Pony, Akka (Armstrong thesis)Fault tolerance for free; horizontal scaling story built inRestrictive for non-distributed code; conflicts with borrow-checked shared memoryHighHardNo — actors as a library, not a language primitive
OO-first (class-based)Program is a hierarchy of classes with inheritanceJava, C#, Simula, Smalltalk (Stroustrup HOPL IV)Familiar to enterprise programmers; large training corpus for LLMsFragile base class; complects state/identity/behavior (Hickey “Simple Made Easy”); Alan Kay called it “the least important half” (Kay HOPL II)MediumHardNo — structs + traits + composition instead
ConcatenativeProgram is a composition of stack effectsForth, Factor, JoyConcise; naturally serializableAlien to modern programmers; hard for LLMs (no positional argument naming)MediumHardNo — reject as primary; borrow only the |> pipeline idiom
Logic programmingProgram is a set of clauses solved by unificationProlog, Datalog, miniKanrenExcellent for constraint problems and analysisNon-decidable in general; hard to give predictable performanceHighHardNo as user-facing paradigm; yes internally for compiler analysis (Datalog is used by rust-analyzer, Polonius)
Hybrid (Mo’s direction)Pure-by-default expressions, imperative when declared, structs+traits, ADTs+pattern matching, first-class effectsRust (approximate), Swift, Roc + Austral inspirationCoherent with Mo’s stated direction; each paradigm’s concept is deployed for what it does bestLarger surface than any single paradigm; requires deliberate integrationMediumHardYes — this is the recommendation

Rationale for the recommendation. Van Roy’s methodology says pick concepts not paradigms. Mo’s needed concepts — purity for reasoning, imperative regions for control, ADTs for data, effect rows for authority, traits for polymorphism — cross paradigm boundaries. The exemplar that most closely matches is Rust with Roc/Austral influence on the effect/capability side.


2. Type system foundation

The type-system menu (Camp B in the research bundle) is the deepest single design axis Mo will decide. Mo’s commitments (contracts, machine verification, capabilities, effects) rule out several options immediately.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
Dynamic (no static types)Types checked at runtime onlyPython, Ruby, JavaScript, Lua, ClojureFastest exploration; least frictionIncompatible with contracts and machine verification; ecosystem-quality problems (Harper)LowHardNo — incompatible with Mo’s premise
GradualStatic and dynamic coexist per-file; any opts outTypeScript, Sorbet, mypy, Elixir (TS handbook; Elixir gradual types)Migration path from dynamic; low frictionEncourages leaving code untyped; complicates verificationMediumMediumNo as foundation; consider a well-defined dynamic escape hatch
Hindley–Milner (global)Whole-program type inference; annotations rareML, OCaml, Haskell, Elm (SPJ Haskell paper)Almost no annotation burdenPoor error messages; global-inference cascade under LLM edits; hard to extend to effectsHighHardNo — bidirectional is strictly better in modern context
System F (bidirectional)Types propagate at binders, inferred at constructorsRust, Swift, Kotlin (in practice) (impl. report §3.2)Excellent errors; local inference; extends naturally to effects/refinements; agent can supply annotations at bindersMore annotations than HM (mostly at function signatures)MediumMediumYes — the mainstream modern answer
Dependent typesTypes can depend on values; arbitrary specificationAgda, Idris, Coq/Rocq, Lean 4, F*, ATS (Lean 4 paper; Idris tutorial)Maximum expressive power for specificationsNon-decidable type checking; requires proof search; steep learning curve even with LLM assistVery HighHardNo — too far from mainstream; use refinement types instead
Refinement typesTypes constrained by decidable predicates; SMT-dispatchedLiquid Haskell, F*, Verus, Prusti (Verus; Dafny)Decidable; contracts naturally expressible; annotation cost paid by agentRequires SMT solver in build pipeline; error messages need investmentHighMediumYes — the machine-verification story lives here
Effect-typedFunction signatures track effects (I/O, exceptions, allocation)Koka, Eff, Frank, OCaml 5, Unison (Koka book; OCaml effects; Unison abilities)Effect discipline enforced by compiler; capabilities integrate naturallyRow inference is compiler engineering; syntax debate openHighMediumYes — combined with capabilities
Linear/affine typesEvery value used exactly (or at most) onceClean, Linear Haskell, Austral, Rust ownership (Austral spec; Idris multiplicities)Precise resource tracking; combines with capabilities for authorityProgrammer must thread values manually if fully linearHighHardYes as an addition — affine on resources, not general values
Capability typesAuthority is a type carried on referencesPony, Wyvern, Austral, E (Pony capabilities paper; Austral capabilities)No ambient authority; supply-chain safety enforced by type systemVerbose without careful syntax design; ecosystem must be builtHighHardYes — combined with effects

Recommendation. Mo’s type system foundation is bidirectional System F + row-typed effects + refinement types + affine handles on resources + capability parameters on effects. The combined system is larger than any single existing language, but it is the sum of concepts that each independently has decade-plus track records. Austral is the closest existing prior art; Verus + Koka + Rust together sketch the rest.


3. Memory model

Memory management is the deepest engineering decision. Once made, the standard library, concurrency runtime, and even the FFI story organize around it.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
ManualProgrammer calls alloc/free explicitlyC, Zig (Zig intro)Maximum control; predictableUse-after-free is a real bug class; painful for high-level codeLowHardNo — even Zig is fighting this
Reference countingEvery value has a refcount; freed at zeroObjective-C ARC, Swift, CPython, PerlDeterministic; low pause; simple mental modelCycle leaks; atomic RC contention; Swift’s ARC limits on concurrencyMediumMediumNo — but ORC-style RC+cycle collector is a viable hybrid escape hatch
Tracing GCRuntime traces roots and collects unreachable memoryJava, Go, Haskell, C#, JavaScript (Go GC latency; G1 tuning)Zero programmer burden; sophisticated in productionGC pauses (even sub-ms is nonzero); memory overhead; complicates effect signaturesHighHardNo — GC pollutes the effect story
Ownership + borrowingAliasing XOR mutability; compile-time checkedRust, Vale (Rust NLL; RustBelt)Compile-time memory safety with no runtime cost; industry-provenSteep learning curve; lifetime-parameter syntax is famously hardHighHardPartial — inspire the safety, drop the lifetime parameters
Region-basedValues allocated in a region; freed at scope endCyclone, MLKit, Vale (Tofte & Talpin; Cyclone; Vale regions)Locally auditable; O(1) deallocation; no lifetime params; matches Mo’s existing VMRestrictive for cyclic or long-lived shared data; region-inference is nontrivialMediumMediumYes — the recommended primary model
Linear / uniquenessEach value used exactly once; enforces move semanticsClean, Linear Haskell, Austral (Austral spec)Precise resource control; combines with capabilitiesErgonomic burden if applied to all valuesHighHardYes on external resources (file handles, sockets), not on ordinary values
Generational referencesRC-free non-owning references with generation-tag runtime checkVale (Vale page)Catches use-after-free without borrow checker; friendly ergonomicsSmall runtime overhead per dereference; young technologyHighMediumConsider as complement to regions for cross-region references
Mutable value semanticsAll values uniquely owned; sharing via projections onlyHylo (Hylo page)No aliasing category; simplifies reasoningConstrains data structures (no easy cyclic graphs); youngHighHardNo — too restrictive for Mo’s expected workloads
Hybrid (ARC + cycle collector)Deterministic RC + async cycle detectionNim ARC/ORC (Nim GC docs)Deterministic; handles cycles; underrated in the fieldRC atomicity cost; still has some runtime costMediumMediumConsider as fallback for cyclic-graph regions
Platform-providedLanguage pure; memory strategy delegated to a runtime “platform”Roc (Roc “Fast”; Roc FAQ)Clean separation; language stays smallRequires platform ecosystem; complicates FFIMediumMediumNo — Mo’s users need direct control

Recommendation. Regions as primary, linear/affine on external resources, ORC hybrid as an escape hatch for cyclic data structures. This combination is closest to what Austral proposes conceptually and what Vale is exploring practically. Rust’s borrow-checker discipline informs the safety story, but Mo’s regions are explicit syntax rather than inferred lifetimes, which sidesteps Rust’s most-complained-about learning barrier.


4. Effect handling

Effect handling determines how side effects show up in types and how programs can intercept/redirect them. This axis is tightly coupled to the type-system foundation.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
Implicit (ambient)Effects invisible in typesPython, Ruby, JS, C, Go, JavaZero annotation burdenAny function can do anything; incompatible with Mo’s capability storyLowEasyNo — undermines Mo’s design
MonadicEffects encoded in return types via monadsHaskell (IO, State, Reader) (Peyton Jones “Hair Shirt”)Complete effect tracking; well-understood theoryMonad transformer stacks are notoriously painful; poor compositionMediumMediumNo — algebraic effects strictly better in modern design
Algebraic effects with handlersEffects declared, handlers give semantics; can resumeKoka, Eff, Frank, OCaml 5, Unison (Koka book; OCaml 5 effects; Multicore OCaml paper; Unison abilities)Composable; unifies exceptions, async, generators, coroutines; row inference is tractableCompiler engineering intensive; handler stack performance requires workHighMediumYes — this is Mo’s recommended model
Capabilities (object)Authority is an unforgeable reference; no ambient accessPony, Austral, E, Wyvern, Roc platforms (Austral capabilities; Pony)Compile-time authority tracking; supply-chain safetyVerbose without careful syntax; must design capabilities into every APIHighHardYes — combined with effects
NoneNo effect tracking at allC, Zig (mostly), GoSimplest possible modelIncompatible with Mo’s premisesLowEasyNo

Recommendation. Algebraic effect handlers combined with capability parameters — the recommended design is an effect row that includes both effect names (<read_fs, http, exn>) and capability parameters (fn foo(cap: &FS) -> <read_fs> Config). Koka’s syntax is the closest published model; Austral’s design is the closest published integration with capabilities.


5. Concurrency model

Concurrency choice determines the shape of the runtime and the standard library. It is hard to reverse after 1.0.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
Threads and locksOS threads with shared memory + mutexesJava, C++, C#, POSIX threadsUniversal; well-understoodData races and deadlocks; hardest concurrency model to get rightLowMediumNo — not the primary model
CSP with channelsIndependent processes communicating over typed channelsGo, Newsqueak, Alef, Limbo, Occam (Hoare CSP; Wikipedia: Newsqueak)Simple mental model; goroutines are cheap”Colored” — hard to make sync code from channel code; channel semantics have sharp edgesMediumMediumConsider as an alternative if effect handlers prove too complex
ActorsIsolated processes with mailboxes; supervision treesErlang, Elixir, Pony, Akka (Armstrong thesis)Fault tolerance; horizontal scaling; production-provenRestrictive for non-distributed code; conflicts with borrow-checked shared memoryHighHardNo as primary; provide as library
Async/awaitCooperative scheduling; futures typedRust, C#, JavaScript, Python, Swift (Aaron Turon on futures)Compile-time control; integrates with typesColored functions problem; ecosystem must be async-awareMediumHardYes as user-facing syntax over effect handlers
Structured concurrencyTask hierarchies; parent scopes await childrenTrio, Swift concurrency, Kotlin coroutines, JEP 505 (JEP 505; Smith on structured concurrency)Prevents dangling tasks; propagates errors and cancellationRequires ecosystem disciplineMediumEasyYes — layer on top of async/await
Software transactional memoryTransactions over shared refs; retry on conflictClojure, GHC HaskellNo manual locking; composablePerformance cost; interacts badly with I/OHighMediumNo — provide as library if at all
Effect-basedConcurrency modeled as an effect handlerKoka, OCaml 5 domains (OCaml 5 effects)Unified with other effect handling; composable with cancellation and retryVery novel; performance engineering nontrivialHighMediumYes as the underlying implementation
None yetShip without concurrency; add laterOriginal Lua, early RubySimpler initial scopeRetrofit is expensive; concurrency-shape decisions leak into APIs—Very HardNo — pick early even if the initial implementation is minimal

Recommendation. Structured concurrency at the surface, implemented via algebraic effect handlers underneath. Users see async/await-like syntax with parent-child task scopes; the compiler translates to effect handler code. Data-race freedom is enforced by the ownership+capability system rather than by Send/Sync traits. If the effect-handler runtime proves too ambitious for 1.0, ship Rust-style async/await with structured concurrency wrappers as an interim design and migrate to effects later.


6. Error handling

Error handling is the surface every function in the language touches. Choices ripple into the type system, the standard library, and even the syntax.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
ExceptionsErrors unwind the stack; caught by handlersJava, C#, Python, C++, RubyFamiliar; low syntactic cost at call siteErrors invisible in signatures; interacts badly with concurrency and borrowingMediumHardNo — invisible errors defeat effect discipline
Result / EitherErrors are values of type Result<T, E>Rust, Haskell, Swift (Result), Roc (Rust book on ?)Errors visible in types; composable; interacts well with pattern matchingSome syntactic overhead (mitigated by ?)LowMediumYes — the modern mainstream answer
Error unionsSimilar to Result, but built into the languageZig (Zig errors docs)Ergonomic; low syntactic cost; error sets are inferrableRequires language-level designMediumMediumConsider — a variation of Result worth studying
Condition systemErrors are conditions; restarts can resume computationCommon LispPowerful; can express recovery patterns not otherwise availableAlien to most programmers; large runtimeHighHardNo — too idiosyncratic
Effect-basedErrors are algebraic effects handled by effect handlersKoka, OCaml 5, Unison (Koka book)Unifies error handling with other effects; supports “resume after handling”Requires effect infrastructure; syntax debate openHighMediumYes — the effect handler is the primitive; Result is sugar
Panic-onlyFatal errors abort; no user-catchable exceptionsEarly Zig (with unreachable); Erlang (let it crash)Simple; enforces recovery via supervisionCannot express recoverable errors ergonomicallyLowMediumNo as sole model; provide panic/abort for truly fatal cases

Recommendation. Effect-based errors surfaced as Result<T, E> sugar. Under the hood, throw and try desugar to raising and handling an <exn> effect. Result<T, E> is the ergonomic form for functions that expose errors as values (with ? for propagation, à la Rust). This unifies the design with effect handling and lets users choose their preferred style.


7. Metaprogramming

Metaprogramming is the extension mechanism for a language. Guy Steele’s Growing a Language argues that the extension mechanism is more important than the initial feature set (Steele, “Growing a Language”).

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
NoneNo user-defined syntactic extensionGo, Zig (mostly)Simplest to implement; guarantees stable parsingUsers cannot build DSLs; boilerplate must be language-levelLowEasyConsider as the starting point
Text macrosPreprocessor-style substitutionC, C++Well-understood; low costNotoriously hazardous; no hygiene; hostile to LLMs and toolsLowEasyNo — universally regretted
Hygienic macrosSyntax rewrite with lexical hygieneScheme (syntax-rules), Rust macro_rules! (Rust reference on macros)Ergonomic for common patterns (deriving, DSLs); safeExtends the language grammar in surprising waysMediumMediumMaybe — small hygienic macros only; ban unbounded rewriting
Procedural macrosUser code runs at compile time to generate codeRust proc-macros, Scala macros, Lisp macros (Rust proc-macro reference)Extremely powerful; enables derive and framework DSLsArbitrary code execution at build time = supply-chain vector; slow builds; hostile to LSPsHighMediumNo by default; treat as a capability that must be explicitly enabled
Staged compilationCompile-time-first language with typed splicingZig comptime, MetaML, TerraType-safe metaprogramming; compile-time execution well-scopedRequires substantial compiler machineryHighMediumConsider — Zig’s model is very promising for a language of Mo’s shape
ReflectionRuntime type introspectionJava, C#, RubyVery flexible for frameworksUndermines type reasoning; runtime overhead; hostile to whole-program optimizationMediumMediumNo — provides no benefit under Mo’s static discipline
Compile-time evaluationPure functions can run at compile timeD (CTFE), C++ constexpr, Zig comptime, Nim (Zig comptime docs)Very useful for constants, table generation, size-parameterized typesRequires effectful/pure distinction to be enforceableMediumEasyYes — Mo’s pure functions should be evaluable at compile time

Recommendation. Compile-time evaluation of pure functions (Zig/Nim style), small derive-only hygienic macros for common patterns, and procedural macros as an opt-in capability that must be declared in the package manifest and enabled by the consumer. Full proc-macros are the single largest supply-chain-security hole in the Rust ecosystem and default-off is the correct posture.


8. Module system

Module systems determine how code is organized, how dependencies are declared, and how names are shared across compilation units.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
Namespace / packageModules are grouping constructs with visibility rulesJava packages, Python modules, Go packages, Rust modules (Rust book on modules)Familiar; simple; predictableCannot parametrize modules directlyLowMediumYes — the mainstream choice
First-class modulesModules are values that can be passed to functionsOCaml, 1ML, Scala objectsVery flexible; unifies module and object systemsComplex type theory; poor error messages historicallyHighHardNo — overkill for Mo
ML functorsModules can be parameterized by other modulesStandard ML, OCaml, CoqGreat for generic abstract-data-type-style librariesVerbose; foreign to modern programmersHighHardNo — traits + generics cover the common cases
ML-style modules with signaturesModules have explicit interfaces (signatures)SML, OCamlExcellent encapsulation and abstractionSignature/structure split is a learning barrierHighHardPartial — Mo should support explicit interface declarations on modules
Content-addressed modulesModules identified by hash of contents, not nameUnison (Unison big idea)Immune to name conflicts and typosquatting; rename is freeHuman-readable references require an index; unfamiliarHighHardYes — as the identity layer under the package system

Recommendation. Namespace/package modules with explicit interface declarations, content-addressed identity in the package manager. The user-facing model is Rust-like (crates + modules); the identity layer under the package registry is content-addressed (Unison/Nix influence).


9. Compilation target

Compilation choice determines developer-time iteration speed, runtime performance, and deployment options.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
LLVMMature IR + backend for native codegenRust, Swift, Julia, Zig, Crystal, OdinHighest-quality native code; supports every targetVery slow compile times; ~100MB compiler binary; complex to integrateHighEasyYes as release-mode option, later
CraneliftRust-implemented fast backend (Wasmtime’s)Wasmtime, Rust JIT experiments (Cranelift page)~10× faster compile than LLVM; production-quality for warm pathsLess-optimized code than LLVM; fewer target triplesMediumEasyYes as primary AOT backend
MLIRLLVM’s newer multi-level IR for heterogeneous computeMojo, TensorFlow, Torch-MLIR (MLIR paper)Ideal for GPU/accelerator targetsVery heavy; overkill without accelerator use caseVery HighMediumNo — Mo isn’t AI-accelerator-shaped
Custom VMOwn bytecode + interpreter/JITErlang BEAM, Python CPython, Lua (BEAM book; Lua VM)Complete control; fast iteration during designNo ecosystem; slower than nativeMediumEasyYes as development-time reference
Transpile to CEmit C, use system C compilerNim, Chicken Scheme, ValaPortable; leverages C toolchainTies Mo to C ABI; complicates novel effects/regionsMediumMediumNo — leaks C’s abstractions
WebAssembly-firstWasm as the primary targetGrain, Roc (partial), Component Model languages (WASI 0.2)Sandboxed by construction; portable; capability-alignedImmature compared to native; performance still catching upMediumEasyYes as additional target once stable

Recommendation. Staged: custom VM for dev iteration → Cranelift AOT for production → LLVM as an optional release-mode backend → Wasm/WASI/Component Model target for portable deployment. Each stage is a reversible engineering choice; the sequencing minimizes wasted effort.


10. Bootstrapping strategy

Bootstrapping is how Mo’s compiler eventually gets written in Mo. Ken Thompson’s “Reflections on Trusting Trust” (Thompson, 1984 Turing lecture) established the ceremony matters.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
Never self-hostCompiler stays in another language foreverTypeScript (was in TS, now in Go 2025)Simplest; least ceremonySignals immaturity; no dogfooding of MoLowEasyNo — self-hosting is a milestone worth reaching
Implement in existing language then self-hostBootstrap compiler in Rust/Go/etc.; migrate to Mo when Mo is capableRust (was in OCaml, then Rust), Swift, JuliaStandard path; low riskDelayed self-hosting means Mo’s early years are spent optimizing an ecosystem it doesn’t useMediumEasyYes — Mo’s current VM path fits this
Self-host from day oneWrite compiler in Mo, bootstrap from a stripped subsetPyPy (partially), some hobby languagesImmediate dogfoodingVery slow initial progress; chicken-and-egg problemVery HighHardNo — premature optimization
Dual-trackMaintain both original-language and self-hosted implementations in parallelZig (currently maintaining Zig-in-C++ and Zig-in-Zig backends)Redundancy; can validate one against the otherDouble the maintenanceHighEasyConsider — Zig’s transition suggests it works
Bootstrappable Builds disciplineTrace the compiler’s provenance back to a small trusted seedGNU Mes, Bootstrappable Builds project (bootstrappable.org)Answers Thompson’s trusting-trust concernSubstantial extra work; only matters for high-assurance usersHighEasyConsider — deferred, but plan for it

Recommendation. Implement Mo’s compiler in Rust (matching the current dev repo), self-host once the language is capable, publish a stage-0 seed for bootstrappability once the language is mature. The transition timing depends on when Mo’s type system and effect system are stable — attempting self-hosting before those are settled means rewriting the compiler repeatedly.


11. Package registry design

Package registries have converged on a common shape, but the details differ enough that the choice matters.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
Central registryOne canonical registry; publishing goes through itnpm, PyPI, crates.io, Hex, Maven CentralSingle source of truth; discoverability; enforce norms uniformlySingle point of failure/censorship; ecosystem lock-inMediumHardYes as default, with federation as escape hatch
FederatedMultiple registries; clients can use anyGo modules (URL-as-identifier) (Go modules ref)No single failure point; enterprise-friendlyFragments discovery; harder to enforce security normsMediumMediumYes as federation layer over central default
Content-addressedPackages identified by hash of contentsNix, Unison (Nix content-addressed; Unison)Eliminates typosquatting; perfectly reproducible; no need for lockfilesUnreadable references without an indexMediumMediumYes as the identifier layer
Git-basedDependencies are git repos, no separate registryGo modules (partly), ZigRadically simple; no publishing ceremonySlower resolution; no metadata search; auth issuesLowEasyNo as primary; can support as ad-hoc source
No registryCopy source into your projectVery early C, Unix traditionSimplest possibleDuplication; no version discoveryLowEasyNo — modern users won’t accept this

Recommendation. Central default registry (registry.mo-lang.org) with federation enabled by default (any HTTPS endpoint serving the standard format), content-addressed identifiers under human-readable labels. This combination is more permissive than crates.io, more secure than npm, and more discoverable than pure Go modules.


12. Package authority model

This axis is where Mo’s design most differs from every existing production language. The default posture for every existing ecosystem is open trust; Mo should default to declared authority.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
Open trustAny published package can be imported and run with full process authoritynpm (mostly), PyPI (mostly), CargoZero friction; fast ecosystem growthEvery supply-chain attack the last decade exploited thisLowVery HardNo — Mo’s rare freedom is to avoid this
Signed and verifiedPackages must be signed by an authenticated publisherHex (GPG), Maven Central (GPG), npm provenanceAttribution; hard to publish anonymouslySignature verifies origin, not intent (SLSA blog)MediumMediumYes — baseline requirement
Capability-declaredEvery package’s manifest declares the capabilities it usesDeno (partly), Austral, Roc (via platforms) (Deno; Austral capabilities)Consumer sees authority up front; transitive authority is checkableVerbose without careful design; ecosystem must be builtHighHardYes — the core of Mo’s design
Sandboxed buildsBuild runs in a hermetic sandbox with no network / limited filesystemBazel remote execution, Nix (Nix)Prevents install-time exfiltration; enables perfect reproducibilityRequires containerization infrastructureHighMediumYes — should be default for mo build
Runtime permission flagsExecutable requires runtime flags to grant permissionsDeno’s --allow-net, Wasm sandbox (Deno v1)Second line of defense after compile-time capability checkRuntime check happens too late in build pipelineMediumEasyYes as complement to compile-time capabilities

Recommendation. Capability-declared manifests + Sigstore-signed OIDC-authenticated publishing + sandboxed builds + runtime capability flags for compiled binaries. This composed defense-in-depth is significantly stronger than any existing production ecosystem, and Mo’s premise (agent authorship, greenfield ecosystem) is what makes it feasible.


13. Build script policy

Related to but distinct from package authority: what code is allowed to run during a build?

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
Arbitrary codePackages can run any code at install/build timenpm postinstall, Python setup.py, Cargo build.rs, Rust proc-macrosMaximum flexibility for legitimate build tasksThe single largest supply-chain vulnerability class of the last decadeLowVery HardNo — never enable by default
Restricted (sandboxed)Build code runs in a sandbox with limited permissionsBazel sandboxed actions, Nix builderLegitimate build code still works; attacks containedSandbox infrastructure is nontrivialHighMediumYes — for build code that is opted in
Declarative-onlyNo arbitrary build code; build is a data structure interpreted by the build toolBazel BUILD files (partially), CMake target definitionsReproducible; auditableExtension mechanism must be more sophisticatedMediumHardYes — the default for Mo builds
Disabled entirelyNo build hooks; everything must be declared in the manifestRare in practiceSimplest security postureLegitimate needs (code generation, native library detection) require language featuresLowMediumNo — too restrictive

Recommendation. Declarative-only build manifests by default; sandboxed build actions as an opt-in capability declared in the manifest and consented to by the consumer. Native code compilation is a capability the consumer opts into per-dependency, not a default. This is stricter than Cargo, Deno, and every existing package manager, and is precisely where Mo’s greenfield freedom pays off.


14. Governance model

Governance is a design decision as much as a syntactic one. It scales differently at different sizes.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
BDFLSingle designer-author with final authorityPython (until 2018), Perl, Ruby, LuaFast decisions; coherent designBus factor 1; burnout risk; illegitimate at scale (LWN — Guido’s resignation)LowEasyYes for pre-1.0 only
Steering councilSmall elected group with delegated topical teamsPython (post-2018), Rust Leadership Council, Swift LSG (Rust RFC 3392; Python PEP 8016)Scalable; resilient; matches large communitiesRequires community large enough to electMediumEasyYes for post-1.0
FoundationIndependent nonprofit owns trademark and infrastructureRust Foundation, Python Software Foundation, Node.js Foundation, .NET Foundation (Rust Foundation launch)Legal cover; corporate credibility; long-term stabilityExpensive (~$500K+/year); requires board governanceHighMediumYes eventually, once corporate adoption warrants
CorporateSingle company owns and directs the languageSwift (Apple), Kotlin (JetBrains), C# (Microsoft), Go (Google)Well-funded; coherentCommunity concerns about single-vendor lock-inMediumHardNo — Mo is not corporate-backed
Community RFCNo formal authority; consensus emerges from RFC discussionsNix (partially), some hobby languagesDemocratic feelDecisions stall; no accountabilityLowEasyNo as sole model; RFC process is a tool, not a governance structure

Recommendation. Staged: BDFL (Robert) with RFC process for pre-1.0 → steering council (3-5 members with at least one non-founder) post-1.0 → foundation once corporate adoption is real. Publish the governance charter at 1.0 so the transition is not a surprise.


15. Standard library scope

Standard library scope determines how much a fresh Mo installation can do without pulling dependencies. Historically this is one of the most-debated ecosystem questions.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
Batteries-includedComprehensive stdlib: HTTP, JSON, cryptography, DB drivers, etc.Python, Java, .NET, GoUsers can do useful work with no dependenciesStandard library evolves at language speed (slow); breaking changes affect everyoneVery HighHardNo — too expensive for a small team
Curated coreMid-sized stdlib: collections, I/O, common utilities; heavier things in official packagesRust, Swift, Zig, ElixirSmall stable core; extensions can iterate independently; ecosystem stays healthyUsers must learn what’s in core vs. what’s externalMediumMediumYes — the mainstream modern answer
Minimal coreTiny stdlib: only what the language semantics requireScheme (minimal), LuaVery stable; easy to auditUsers must depend on third-party packages for everythingLowEasyNo — too little for productive use
Runtime-providedLanguage provides no stdlib; runtime/platform doesRoc (via platforms) (Roc “Fast”)Language stays tiny; multiple runtimes possibleRequires platform ecosystemMediumMediumConsider — a variation worth studying

Recommendation. Curated core: collections, I/O with capability requirements, common utilities, contracts/refinements support, effect handler primitives. Everything else in official-but-separate packages. Rust’s model is the reference. Mo’s stdlib should be small enough that a single maintainer can review every change.


16. Backward compatibility policy

Backward-compatibility policy is a promise to users that shapes their willingness to invest in the language.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
Never breakEvery version compiles all prior codeJava (mostly), Go 1 compatibility promise (Go 1 compat)Users can upgrade fearlesslyOssification; cannot fix past design mistakes——Consider — combined with editions
Editions / epochsSmall breaking changes allowed per edition; per-crate opt-in; mechanical migrationRust (2015, 2018, 2021, 2024) (Rust editions)Best of both worlds: evolution + stabilityComplexity in tooling; edition boundaries require careful designMediumEasy (if planned)Yes — the recommended model
Semantic versioning strictFollow semver mechanically; major = breakingCargo semver checks, most modern ecosystemsWidely understoodSemver is a promise easily broken in practice (Reprog critique); Hyrum’s law says users depend on all observable behaviorLowEasyYes — combined with editions
Major version breaksBreak freely at major versionsPython 2→3, Scala 2→3, Perl 6Ability to fix past designMassive user migration cost; often ecosystem-destroying (Perl 6, Python 3 pain)—HardNo — the cautionary tales are decisive
Rolling deprecationFeature marked deprecated → warning → removed over N releasesMany languages informallyPredictable; users have time to migrateRequires disciplined communicationLowEasyYes — as the day-to-day process

Recommendation. Rust-style editions from day one (each source file declares edition = "1"), semver for the compiler, rolling deprecations for stdlib, and Go-1-style compatibility promise within an edition. Make the migration tooling (mo fix --edition) a first-class feature.


17. Syntax family

Syntax family is largely aesthetic but has real ergonomic and technical implications, especially under LLM authorship.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
C-family curly bracesStatements terminated by ;, blocks delimited by {}C, C++, Java, C#, JavaScript, TypeScript, Rust, Go, Swift, ZigFamiliar to majority of programmers; unambiguous grammar; excellent for LLM incremental generationSomewhat verboseLowVery HardYes — the mainstream modern answer
ML expression-orientedEverything is an expression; whitespace-independentML, OCaml, F#, Haskell, Elm, ScalaExcellent for functional composition; conciseFewer syntactic anchors for LLMs; can be terse to the point of unreadableLowVery HardConsider — hybrid works (Rust is expression-oriented within C-family syntax)
Lisp S-expressionsEverything is (head args...); homoiconicCommon Lisp, Scheme, Clojure, RacketTrivially LL(1); enables powerful macrosAlien to most programmers; ambiguous grammar for LLMs (parens are underloaded); no unique anchorsLowVery HardNo — closes off too much
Python-style indentationBlocks delimited by indentationPython, Haskell (layout), Nim, F#Concise; visually cleanIndentation-sensitive lexing is hostile to LLM incremental generation (history/03_2010_to_2026.md, §4.1)MediumVery HardNo — LLM-hostility is decisive
Hybrid (Mo’s direction)C-family curly braces + expression-oriented semanticsRust, SwiftBest of both; industry-provenRequires careful spec designLowVery HardYes — the recommendation

Recommendation. C-family curly braces with expression-oriented semantics (Rust/Swift model), LL(1) or LALR(1) grammar, mandatory semicolons or newlines with explicit continuation, no user-defined operator precedence, and a canonical formatter (mo fmt) with no options.


18. Verification integration

Verification integration is where Mo’s premise — machine verification has stronger leverage than novel syntax — most directly cashes out.

OptionWhat it isExemplar languagesPros for MoCons for MoImpl costReversibilityRecommended?
NoneNo compiler-side verification beyond type checkingC, Zig, GoSimplest; no solver dependencyUndermines Mo’s central design betLowEasyNo — inconsistent with Mo’s premise
Refinement (SMT-checked)Types constrained by decidable predicates; SMT-solved at compile timeLiquid Haskell, F*, Verus, Prusti (Verus; Prusti)Contracts naturally expressible; annotations affordable for agents; usually decidableRequires Z3/CVC5 in build pipeline; error messages need investmentHighMediumYes — the recommendation
Dependent-adjacentTypes can depend on limited values (e.g., array indexing)Dependent Haskell (partial), F*More expressive than pure refinementApproaches undecidabilityHighHardConsider — a graduation path from refinement
Proof-first (dependent)Full dependent types; user writes proofsAgda, Idris, Coq/Rocq, Lean 4 (Lean 4)Maximum expressive powerToo heavyweight for a general-purpose language; steep learning curveVery HighHardNo — but interop with Lean/F* as an export target is worth considering
Hybrid (staged)Ordinary code type-checks; verified subset uses SMT-backed contractsF*, Dafny, VerusUsers pay verification cost only where warrantedRequires two-mode compilerHighMediumYes — the practical form
Model-checking integrationBounded model checker as an external toolKani for Rust, TLA+ for design (Kani docs)Automatic; no proofs neededOnly sound within boundHighEasyConsider — a complementary tool

Recommendation. Hybrid: ordinary Mo code type-checks with bidirectional inference; SMT-backed refinement types and contracts are opt-in via annotations that dispatch to Z3 at compile time. Provide a --verify flag that runs the SMT checks (they can be skipped in fast-iteration builds). This mirrors Verus and Dafny; it is the modern practical form of verification integration.


The following combination picks one option from each axis to form a coherent starting stack. The choices reinforce each other: the type system supports the effect discipline, the memory model supports the concurrency runtime, the tooling supports the LLM authorship premise, and the package system supports the capability discipline.

AxisChoice
1. Paradigm blendPure-by-default expressions, imperative regions, structs+traits, ADTs+pattern matching
2. Type systemBidirectional System F + row-typed effects + refinement types + affine handles + capability parameters
3. Memory modelRegions as primary, affine on external resources, ORC hybrid escape hatch
4. Effect handlingAlgebraic effect handlers + capability parameters (Koka + Austral synthesis)
5. Concurrency modelStructured concurrency surface over effect-handler runtime; fall back to async/await if effects too complex for 1.0
6. Error handlingEffect-based errors, surfaced as Result<T, E> sugar
7. MetaprogrammingCompile-time evaluation of pure functions (Zig-style); derive-only hygienic macros; proc-macros default-off (opt-in capability)
8. Module systemNamespace/package modules with explicit interfaces; content-addressed identity in the registry
9. Compilation targetCustom VM → Cranelift AOT → LLVM release option → Wasm/WASI/Component Model
10. BootstrappingCompiler in Rust; self-host once type/effect system stable; publish stage-0 seed later
11. Package registryCentral default + federation; content-addressed identifiers under human labels
12. Package authorityCapability-declared manifests + Sigstore OIDC signing + sandboxed builds
13. Build script policyDeclarative-only by default; sandboxed opt-in
14. GovernanceBDFL (Robert) pre-1.0 → steering council post-1.0 → foundation later
15. Standard library scopeCurated core (like Rust); rest as official packages
16. Backward compatibilityRust-style editions from day one; semver + rolling deprecations
17. Syntax familyC-family curly braces + expression-oriented semantics; LL(1)/LALR(1); mandatory terminators
18. Verification integrationHybrid: refinement types and contracts opt-in, SMT-backed via Z3

Why these choices reinforce each other

  • Type system + memory model + effects. Refinement types can predicate over regions (region r where all_freed(r)), affine handles let capabilities be linear-typed resources, and effect rows include capability parameters. The three are one integrated system, not three separate features.
  • Effect handlers + concurrency + error handling. Async is an effect; errors are an effect; cancellation is an effect. All flow through the same handler mechanism, which reduces the mental model to a single concept.
  • Syntax + compilation + tooling. LL(1)/LALR(1) grammar makes tree-sitter, LSP, and grammar-constrained LLM decoding trivially implementable. C-family curly braces integrate with the mainstream tooling ecosystem.
  • Package authority + effects + capabilities. A package’s declared capabilities in the manifest correspond directly to the capabilities its code carries in function signatures. The compiler enforces subset consistency: a package cannot use capabilities its manifest does not declare.
  • Bootstrapping + governance + standard library. A small stdlib is maintainable by a single BDFL; a stdlib written in Mo becomes possible once the language self-hosts; a foundation eventually funds the ongoing maintenance.
  • Verification + agent authorship + backward compatibility. Editions let the verification vocabulary evolve without breaking existing verified code; agent-supplied annotations amortize the cost of a verifier that would be too expensive for pure human authorship.

The starting stack is opinionated but not narrow — every choice above is defensible with historical evidence, and every choice above admits a fallback (documented in the tables) if the primary design proves too ambitious.


Provocative alternatives

Two coherent alternatives to the starting stack are worth articulating, if only to make the primary choice more considered. A third stack is included as a “what if Mo were much smaller in scope” thought experiment.

Alternative 1 — The “Rust with better manifest security” stack

This alternative keeps most of Rust’s design but focuses innovation entirely on the supply-chain security layer. It would look like:

AxisChoice
ParadigmRust-shaped
Type systemRust’s affine+trait system (no refinement types, no full effects)
Memory modelRust ownership + borrowing with lifetime parameters
Effect handlingNone (implicit like Rust today)
ConcurrencyAsync/await (Rust-shaped)
Error handlingResult<T, E> + ? (Rust-shaped)
Package registryCentral + federated + capability-declared manifest + default-off build scripts + OIDC publisher signing + release-age gates
All other axesMatch Rust’s current choices

Argument for: minimizes design risk, maximizes the chance of shipping 1.0 quickly, ports the entire Rust ecosystem of tooling knowledge. The differentiator is only the package security story. Argument against: gives up Mo’s biggest design bet — that agent authorship inverts annotation economics for effects and refinement types. Mo becomes “Rust with a better cargo” rather than “the AI-era language.”

Alternative 2 — The “Verus/Dafny-shaped, verify-heavy” stack

This alternative pushes further into verification than the primary recommendation, closer to Dafny or F* in ambition.

AxisChoice
ParadigmPure functional-first (like Roc or F*)
Type systemRefinement + dependent-adjacent types; SMT-verified by default
Memory modelRoc-style platform-provided (language is pure; runtime handles allocation)
Effect handlingEffect rows with handlers
ConcurrencyEffect-based
Error handlingEffect-based
MetaprogrammingStaged compilation only
Standard libraryMinimal core, everything else in verified packages
VerificationEvery function has pre/post/invariant contracts; SMT check is default-on

Argument for: fully realizes the “verification renaissance” bet documented in the AI-era history (history/03_2010_to_2026.md, §4.5); Mo would ship as the first language where every stdlib function has a machine-checked contract. Argument against: hugely ambitious; extends the timeline to 1.0 by years; requires Mo to compete with F* and Dafny on their home turf; may produce a language too specialized for general use.

Alternative 3 — The “Unison + capabilities, everything content-addressed” stack

The most provocative alternative: bet the entire language on content-addressed code and capabilities, following Unison to its logical conclusion.

AxisChoice
Module systemContent-addressed everywhere (no filenames, no imports; functions referenced by hash)
Package systemNo traditional registry — a distributed content-addressed store like IPFS
Effect handlingUnison abilities
Type systemBidirectional + refinement + capability + ability rows
MetaprogrammingNone (pure content-addressed code is metaprogrammable via ordinary function composition)
Backward compatibilityNot a concept — every function’s hash is stable, so old functions are always callable

Argument for: eliminates entire classes of problems (typosquatting, dependency-version conflicts, name collisions, backward-compatibility breaks) by architectural decision. Uniquely well-suited to a world of AI-authored code where functions might have no natural human name. Argument against: extremely unfamiliar to the target user base; requires Mo to build a content-addressed distribution infrastructure Unison is still working out (Unison learn); social friction of “no filenames” is real.


Living-document reminders

This matrix is intended to be updated as design decisions solidify. Practical maintenance:

  • When a decision is finalized in an RFC, mark the row Chosen and add the RFC number in the “Recommended?” column.
  • When a design decision is rejected in an RFC, mark the row Rejected with the RFC number.
  • Add new rows as new options emerge — the field is expanding faster than at any prior point.
  • Cross-reference the RFC repo from the matrix so future contributors can trace decisions to their rationales.

The matrix is not a substitute for the deeper analysis in mo_synthesis.md and the source reports; it is a navigation aid for reasoning about Mo’s design as a whole rather than as isolated choices.