Skip to content

Ultraviolet Developer Handbook

Docs / Handbook

The Ultraviolet Developer Handbook is the public reference for learning and writing Ultraviolet. It is generated from the handbook chapter parts maintained in the language repository and published here as stable website pages.

Generated handbook. Source snapshot: handbook SHA-256: a5d21aff583bfbb6d9db8ef52b842fec80adad1864f5846488ab5bc00e090e24
  1. 1. Introduction & Design Philosophy
    1. 1.1 What Ultraviolet Is
      1. What "general-purpose" and "systems" mean here
    2. 1.2 The Four Foundational Design Rules
      1. 1.2.1 One Correct Way
      2. 1.2.2 Local Reasoning
      3. 1.2.3 Explicit over Implicit
      4. 1.2.4 Static by Default
    3. 1.3 The Mental Model a Developer Should Hold
      1. How the philosophy shapes API and module design
    4. 1.4 The Language Design Contract (§0.4)
    5. 1.5 How the Specification and Handbook Are Organized
      1. 1.5.1 Document Organization (§0.1)
      2. 1.5.2 Canonical Chapter Outline (§0.2)
      3. 1.5.3 Required Feature-Section Template (§0.1 / §0.3)
      4. 1.5.4 The shape of the surface language
    6. 1.6 Idioms & Best Practices
    7. 1.7 Pitfalls & Diagnostics
  2. 2. Conformance, Behavior Types & the Phase Model
    1. 2.1 Conformance (§1.1)
      1. 2.1.1 The conformance predicate
      2. 2.1.2 The phase-order judgments
      3. 2.1.3 Translation phases and rejection
      4. 2.1.4 The entry-point check (MainCheck)
      5. 2.1.5 Constructs (the conformance surface)
    2. 2.2 Behavior Types (§1.2)
      1. 2.2.1 Ill-formed programs
      2. 2.2.2 Statically-undefined behavior
      3. 2.2.3 OutsideConformance (the "anything may happen" category)
      4. 2.2.4 Static versus runtime checks
      5. 2.2.5 Implementation-defined behavior
      6. 2.2.6 Error recovery and diagnostic limits
      7. 2.2.7 Worked example: choosing the right behavior category
    3. 2.3 Document Conventions and Notation (§1.3)
      1. 2.3.1 Normative keywords
      2. 2.3.2 Diagnostic code format
      3. 2.3.3 Notation used throughout the handbook
    4. 2.4 Normative References (§1.4)
    5. 2.5 Compile-Time Execution and Phase Ordering (§1.5)
      1. 2.5.1 The four phases
      2. 2.5.2 The five ordering requirements
      3. 2.5.3 Compile-time forms (syntax)
      4. 2.5.4 Worked example: compile-time versus run-time evaluation
    6. 2.6 Target and ABI Assumptions (§1.6)
      1. 2.6.1 Target profiles
      2. 2.6.2 Architecture, endianness, and pointer size
      3. 2.6.3 LLVM target triples
      4. 2.6.4 Where ABI and layout are actually defined
    7. 2.7 Idioms & Best Practices
    8. 2.8 Pitfalls & Diagnostics
  3. 3. Projects, Manifest, Modules & the Compilation Model
    1. 3.1 Core Project Records
      1. Validation scope
      2. The entry procedure
      3. Command-line output and diagnostics
    2. 3.2 The Ultraviolet.toml Manifest
      1. Project-root discovery
      2. Parsing the manifest
      3. Top-level schema
      4. The [assembly] table
      5. The [toolchain] table
      6. The [build] table
      7. Worked manifest
    3. 3.3 Assemblies and Project Loading
      1. Deterministic manifest validation
      2. Building one assembly
      3. Module ownership across assemblies
      4. Selecting the target assembly
      5. Worked load (skeleton)
      6. Assembly graph constraints
    4. 3.4 Deterministic Ordering and Case Folding
    5. 3.5 Source Roots, Module Directories, and Compilation Units
      1. Source root
      2. Module directories and compilation units
      3. Mapping the filesystem to the module tree
      4. Module discovery
      5. Worked layout
    6. 3.6 Output Artifacts and Linking
      1. Output root and directory layout
      2. Object-file naming
      3. Final artifact naming
      4. Which modules get emitted
      5. IR emission
      6. Linking, archiving, finalizing
      7. Module symbol naming
    7. 3.7 Tool Resolution and IR Assembly Inputs
    8. 3.8 Project Diagnostics
    9. The uv Command Line
    10. Idioms & Best Practices
    11. Pitfalls & Diagnostics
  4. 4. Source Text & Lexical Structure
    1. 4.1 Source Loading and Normalization
      1. 4.1.1 Encoding: UTF-8 and Unicode Scalars
      2. 4.1.2 BOM Handling
      3. 4.1.3 Line-Ending Normalization
      4. 4.1.4 Unicode Normalization
      5. 4.1.5 Prohibited Code Points
      6. 4.1.6 The Loading Pipeline (Big-Step)
    2. 4.2 Lexical Analysis
      1. 4.2.1 Character Classes
      2. 4.2.2 Keywords and Reserved Lexemes
      3. 4.2.3 Identifiers
      4. 4.2.4 Integer Literals
      5. 4.2.5 Floating-Point Literals
      6. 4.2.6 Boolean and Null Literals
      7. 4.2.7 Character Literals
      8. 4.2.8 String Literals
      9. 4.2.9 Escape Sequences
      10. 4.2.10 Operators and Punctuators
      11. 4.2.11 Comments and Doc Comments
      12. 4.2.12 Maximal Munch and Token Selection
      13. 4.2.13 Newlines and Statement Termination
      14. 4.2.14 Lexical Security: Bidi, Confusables, and Mixed Scripts
    3. 4.3 Source Loading and Lexical Diagnostics
    4. Idioms & Best Practices
    5. Pitfalls & Diagnostics
  5. 5. Names, Scopes & Visibility
    1. 5.1 The Scope Context and Identifier Kinds (§7.1)
      1. 5.1.1 The resolution context Γ
      2. 5.1.2 The scope stack
      3. 5.1.3 Entities
      4. 5.1.4 The universe scope and reserved names
      5. 5.1.5 Reserved-identifier predicates
      6. 5.1.6 Keyword keys
    2. 5.2 Name Introduction and Module Validation (§7.2)
      1. 5.2.1 The Intro rules
      2. 5.2.2 Local binding goes through Intro
      3. 5.2.3 UsingAlias: the sanctioned way to make a second name
      4. 5.2.4 Module-name validation
    3. 5.3 Lookup and Qualified Resolution (§7.3)
      1. 5.3.1 Unqualified lookup
      2. 5.3.2 Kind-checked resolvers
      3. 5.3.3 The :: operator and qualified resolution
    4. 5.4 Visibility and Accessibility (§7.4)
      1. 5.4.1 The accessibility judgment
      2. 5.4.2 Top-level visibility
      3. 5.4.3 Visibility and using re-exports
    5. 5.5 Top-Level Name Collection (§7.5)
      1. 5.5.1 What each declaration binds
      2. 5.5.2 Collecting and rejecting duplicates
      3. 5.5.3 Derived name maps
    6. 5.6 Qualified Disambiguation (§7.6)
    7. 5.7 Shared Resolution Helpers and the Resolution Pass (§7.7)
      1. 5.7.1 Scope push and type-parameter bindings
      2. 5.7.2 Resolving type, class, and value paths
      3. 5.7.3 Resolving expressions
      4. 5.7.4 Module path validation and the module driver
    8. 5.8 Referencing Names Across Modules and Assemblies
    9. 5.9 Idioms & Best Practices
    10. 5.10 Pitfalls & Diagnostics
  6. 6. Module-Level Forms: Imports, Using, Statics & Extern Shell
    1. 6.1 Import Declarations (§11.1)
      1. Syntax
      2. Semantics
      3. Diagnostics
      4. Worked Example
    2. 6.2 Using Declarations (§11.2)
      1. Syntax
      2. 6.2.1 Single-item using
      3. 6.2.2 Using list
      4. 6.2.3 Using wildcard (module::*)
      5. Diagnostics
    3. 6.3 Static Declarations (§11.3)
      1. Syntax
      2. Semantics and mandatory rules
      3. Initialization, ordering, and naming
      4. Diagnostics
      5. Worked Example
    4. 6.4 The Extern Block Shell (§11.4)
      1. Syntax
      2. Semantics
      3. Worked Example (shell only)
    5. 6.5 Module and File Aggregation (§11.5)
      1. 6.5.1 Directories are modules; files aggregate
      2. 6.5.2 Well-formed module paths
      3. 6.5.3 Import coverage — the rule that ties §11.1 and §11.2 together
      4. 6.5.4 Path resolution
      5. 6.5.5 Initialization ordering
      6. Diagnostics
      7. Worked Example (layout)
    6. Idioms & Best Practices
    7. Pitfalls & Diagnostics
  7. 7. The Type System Core: Equivalence, Subtyping & Inference
    1. 7.1 Type Equivalence (≡)
      1. 7.1.1 The shape of the rules
      2. 7.1.2 Unions: equivalence is permutation-closed
      3. 7.1.3 Array lengths: ConstLen
      4. 7.1.4 Refinements: subject-normalized predicate equality
      5. 7.1.5 The equivalence-relation closure
    2. 7.2 Subtyping (<:)
      1. 7.2.1 Where subtyping does *not* widen: numerics and permissions
      2. 7.2.2 The bottom type
      3. 7.2.3 Structural (covariant) subtyping
      4. 7.2.4 Pointer and modal subtyping
      5. 7.2.5 Functions, closures, and async: contravariant parameters
      6. 7.2.6 Union subtyping: membership and width
      7. 7.2.7 Generic subtyping and declared variance
      8. 7.2.8 Reflexivity and transitivity
    3. 7.3 Type Inference
      1. 7.3.1 Type variables and substitutions
      2. 7.3.2 The unifier
      3. 7.3.3 The solver
      4. 7.3.4 Bidirectional synthesis and checking
      5. 7.3.5 Inference for literals
      6. 7.3.6 Subsumption, pointer-null, and modal subsumption at use sites
      7. 7.3.7 Where types may be omitted, and where they are required
      8. 7.3.8 Inference for generics
      9. 7.3.9 Inference for tuples, arrays, and unions
    4. 7.4 Metatheoretic Properties
      1. 7.4.1 The step relation
      2. 7.4.2 The guarantees
    5. 7.5 Core Type Diagnostics
    6. 7.6 Idioms & Best Practices
    7. 7.7 Pitfalls & Diagnostics
  8. 8. Primitive & Aggregate Data Types
    1. 8.1 Primitive Types
      1. 8.1.1 Exact syntax
      2. 8.1.2 Integer types — exact names, widths, and signedness
      3. 8.1.3 Floating-point types
      4. 8.1.4 bool, char, unit, never
      5. 8.1.5 Integer and float literal/type pairing rules
      6. 8.1.6 Diagnostics
    2. 8.2 Tuples
      1. 8.2.1 Exact syntax
      2. 8.2.2 Construction, indexing, arity
      3. 8.2.3 Diagnostics
    3. 8.3 Arrays
      1. 8.3.1 Exact syntax
      2. 8.3.2 Declaration, literals, length
      3. 8.3.3 Indexing and bounds
      4. 8.3.4 Layout
      5. 8.3.5 Diagnostics
    4. 8.4 Slices
      1. 8.4.1 Exact syntax
      2. 8.4.2 Views, length, sub-slicing
      3. 8.4.3 Layout
      4. 8.4.4 Diagnostics
    5. 8.5 Ranges
      1. 8.5.1 Exact syntax
      2. 8.5.2 The six range forms and their types
      3. 8.5.3 Layout
      4. 8.5.4 Diagnostics
    6. 8.6 Records
      1. 8.6.1 Exact syntax
      2. 8.6.2 Field visibility
      3. 8.6.3 Construction expressions
      4. 8.6.4 Field access
      5. 8.6.5 On functional update
      6. 8.6.6 Layout
      7. 8.6.7 Diagnostics
    7. 8.7 Enums
      1. 8.7.1 Exact syntax
      2. 8.7.2 Variant forms
      3. 8.7.3 Discriminants and representation
      4. 8.7.4 Construction
      5. 8.7.5 Diagnostics
    8. 8.8 Union Types
      1. 8.8.1 Exact syntax
      2. 8.8.2 Semantics
      3. 8.8.3 Layout
      4. 8.8.4 Diagnostics
    9. 8.9 Type Aliases
      1. 8.9.1 Exact syntax
      2. 8.9.2 Semantics
      3. 8.9.3 Diagnostics
    10. 8.10 Shared Data-Type Diagnostics
    11. Idioms & Best Practices
    12. Pitfalls & Diagnostics
  9. 9. Modal Types & Typestate
    1. 9.1 Modal Declarations (§13.1)
      1. Syntax
      2. Naming
      3. Semantics and well-formedness
      4. Worked example: the declaration shape
      5. Runtime representation and layout (§13.1.5–§13.1.6)
      6. Built-in modal types
      7. Constructing a state value
    2. 9.2 State Fields (§13.2)
      1. Syntax
      2. Semantics
      3. Worked example
    3. 9.3 State-Specific Methods (§13.3)
      1. Syntax
      2. Receiver forms
      3. Invocation
      4. Semantics
      5. Worked example
    4. 9.4 Transitions (§13.4)
      1. Syntax
      2. Semantics
      3. Worked example
    5. 9.5 Modal Widening (§13.5)
      1. Syntax
      2. Semantics
      3. Worked example
    6. 9.6 Matching and Dispatch on Modal State (§13.1.5, §16.7, Chapter 17)
      1. Modal patterns
      2. The if ... is { ... } form
      3. Worked example: exhaustive dispatch
      4. Single-arm narrowing
    7. 9.7 A Complete Worked Lifecycle
    8. 9.8 Modal vs. Booleans and Enums — When to Use Which
    9. 9.9 Idioms & Best Practices
    10. 9.10 Pitfalls & Diagnostics
  10. 10. Strings, Bytes & Text Handling
    1. 10.1 The Two Type Families at a Glance
      1. 10.1.1 Exact Syntax
      2. 10.1.2 The Type Surface
      3. 10.1.3 The Dynamic Model: Everything Is a Byte Sequence
      4. 10.1.4 Lowering
    2. 10.2 String Types (§13.6)
      1. 10.2.1 The Operation Surface
      2. 10.2.2 String Literals and the string@View Type
      3. 10.2.3 Length and Emptiness
      4. 10.2.4 Constructing an Owned string@Managed
      5. 10.2.5 Borrowing a View From an Owned String
      6. 10.2.6 Slicing With UTF-8 Boundary Safety
      7. 10.2.7 Appending to an Owned String
      8. 10.2.8 Conversions and Encoding Guarantees
      9. 10.2.9 Worked Example: Read-Only Inspection
    3. 10.3 Bytes Types (§13.7)
      1. 10.3.1 The Operation Surface
      2. 10.3.2 The Element Type Is u8, Reached Through as_slice
      3. 10.3.3 Length, Emptiness, and Iteration
      4. 10.3.4 Constructing Owned Bytes
      5. 10.3.5 Borrowing Views and Slices
      6. 10.3.6 Appending and Building Bytes
    4. 10.4 Bridging String and Bytes
      1. 10.4.1 bytes::view_string (string → bytes)
      2. 10.4.2 bytes::view (slice → bytes)
    5. 10.5 Idioms & Best Practices
    6. 10.6 Pitfalls & Diagnostics
  11. 11. Pointers, Function Types & Closures
    1. 11.1 Safe Pointer Types (Ptr<T>)
      1. 11.1.1 Exact syntax
      2. 11.1.2 The pointer-state lattice and its semantics
      3. 11.1.3 Creation: address-of (&) and region allocation
      4. 11.1.4 Dereference (*)
      5. 11.1.5 Null pointers: Ptr::null()
      6. 11.1.6 Layout, copying, and the @Valid niche
    2. 11.2 Raw Pointer Types (*imm T, *mut T)
      1. 11.2.1 Exact syntax
      2. 11.2.2 Where raw pointers may be used
      3. 11.2.3 Dynamic semantics: panics, not UB
    3. 11.3 Function Types
      1. 11.3.1 Exact syntax
      2. 11.3.2 Procedures as first-class values
    4. 11.4 Closure Types and Closure Expressions
      1. 11.4.1 Closure type syntax
      2. 11.4.2 Closure expression syntax
      3. 11.4.3 Capture classification
      4. 11.4.4 Local vs escaping closures, and the dependency clause
      5. 11.4.5 Calling closures and the pipeline operator
      6. 11.4.6 Closure representation and layout
    5. 11.5 Choosing the Right Indirection
    6. 11.6 Idioms & Best Practices
    7. 11.7 Pitfalls & Diagnostics
  12. 12. Generics & Parametric Polymorphism
    1. 12.1 Generic Parameter and Argument Syntax
      1. 12.1.1 Grammar
      2. 12.1.2 Parameter Form and Naming
      3. 12.1.3 Variance
      4. 12.1.4 Class Bounds (<:)
      5. 12.1.5 Foundational Class Bounds
      6. 12.1.6 Parameter Defaults (= type)
      7. 12.1.7 No Const / Value Generic Parameters
      8. 12.1.8 No Runtime Semantics
    2. 12.2 Generic Procedures and Generic Types
      1. 12.2.1 Grammar
      2. 12.2.2 Declaring a Generic Procedure
      3. 12.2.3 Calling a Generic Procedure: Explicit Type Arguments
      4. 12.2.4 Type-Argument Inference
      5. 12.2.5 Generic Records and Other Nominal Types
      6. 12.2.6 Generic Type Aliases
      7. 12.2.7 Monomorphization Model and Cost
    3. Idioms & Best Practices
    4. Pitfalls & Diagnostics
  13. 13. Classes, Implementations & Associated Types
    1. 13.1 Classes (spec §14.3)
      1. Exact syntax
      2. Semantics
      3. Well-formedness rules (§14.3.4)
      4. Superclasses, linearization, and effective members
      5. class vs record vs modal
      6. Worked example: a class with abstract and default methods
      7. Worked example: a class with required fields and a superclass
      8. Worked example: a modal class (abstract states)
    2. 13.2 Implementations (spec §14.4)
      1. Exact syntax
      2. Semantics: what an implementer must provide
      3. Coherence and the orphan rule (§14.4.4)
      4. Lowering
      5. Worked example: a record implementing a class
      6. Worked example: a modal implementing a modal class
    3. 13.3 Associated Types (spec §14.5)
      1. Exact syntax
      2. Semantics
      3. Worked example: abstract and defaulted associated types
    4. 13.4 Dynamic Class Objects (spec §14.6)
      1. Exact syntax
      2. Semantics: dispatchability
      3. Method resolution and dispatch
      4. Vtable layout and cost model (§14.6.6)
      5. Worked example: dynamic dispatch over $RenderTarget
    5. Idioms & Best Practices
    6. Pitfalls & Diagnostics
  14. 14. Opaque, Refinement & Capability Classes
    1. 14.7 Opaque Types
      1. 14.7.1 Syntax
      2. 14.7.2 Parsing
      3. 14.7.3 AST Representation
      4. 14.7.4 Static Semantics
      5. 14.7.5 Dynamic Semantics
      6. 14.7.6 Lowering
      7. 14.7.7 Worked Example
    2. 14.8 Refinement Types
      1. 14.8.1 Syntax
      2. 14.8.2 Parsing
      3. 14.8.3 AST Representation
      4. 14.8.4 Static Semantics
      5. 14.8.5 Dynamic Semantics
      6. 14.8.6 Lowering
      7. 14.8.7 Worked Examples
    3. 14.9 Capability Classes
      1. 14.9.1 Syntax
      2. 14.9.2 Parsing
      3. 14.9.3 The Capability Universe and CapClass
      4. 14.9.4 Static Semantics
      5. 14.9.5 The Authority / Context Model
      6. 14.9.6 Dynamic Semantics and Lowering
      7. 14.9.7 Worked Examples
    4. 14.10 Foundational Classes
      1. 14.10.1 Syntax
      2. 14.10.2 AST Representation and Structural Relations
      3. 14.10.3 Static Semantics
      4. 14.10.4 Dynamic Semantics
      5. 14.10.5 Lowering
      6. 14.10.6 Worked Examples
    5. 14.11 Refinement and Polymorphism Diagnostics Supplement
    6. Idioms & Best Practices
    7. Pitfalls & Diagnostics
  15. 15. Procedures, Methods & Overloading
    1. 15.1 Procedure Declarations
      1. 15.1.1 Exact Syntax
        1. Parameters and the move mode
        2. Permission annotations on parameter types
        3. Return types, -> (), and the explicit-return rule
        4. The main entry point
      2. 15.1.2 Semantics
      3. 15.1.3 Worked Example — a free procedure
      4. 15.1.4 Diagnostics (§15.1.7)
    2. 15.2 Methods and Receivers
      1. 15.2.1 Exact Syntax
      2. 15.2.2 Receiver forms and their meaning
        1. Mutable (unique) receivers
        2. Explicit self receivers must be Self
        3. Receiver permission at the call site
      3. 15.2.3 How methods attach to types
      4. 15.2.4 Semantics
      5. 15.2.5 Worked Example — a method with a mutable receiver
      6. 15.2.6 Diagnostics (§15.2.7)
    3. 15.3 Overloading
      1. 15.3.1 Free-procedure overload resolution
      2. 15.3.2 Method and inherited-default resolution
      3. 15.3.3 Worked Example — a free-procedure overload set
      4. 15.3.4 Diagnostics (§15.3.7)
    4. Idioms & Best Practices
    5. Pitfalls & Diagnostics
  16. 16. Contracts: Preconditions, Postconditions, Invariants & Verification
    1. 16.1 The Contract Clause (§15.4)
      1. 16.1.1 Exact syntax
      2. 16.1.2 Semantics: predicates must be bool and pure
      3. 16.1.3 Worked example: a contract on a public API
    2. 16.2 Preconditions (§15.5)
      1. 16.2.1 Syntax and elision
      2. 16.2.2 Semantics: the caller proves the precondition
      3. 16.2.3 Worked example: a precondition the caller can prove
    3. 16.3 Postconditions: @result and @entry (§15.6)
      1. 16.3.1 Syntax
      2. 16.3.2 @result — the returned value
      3. 16.3.3 @entry(expr) — entry-state snapshots
    4. 16.4 Invariants (§15.7)
      1. 16.4.1 Exact syntax
      2. 16.4.2 Type-invariant semantics
      3. 16.4.3 Loop-invariant semantics
    5. 16.5 Verification Logic: what is proved vs checked (§15.8)
      1. 16.5.1 The decision: static proof first, dynamic check only in #dynamic
      2. 16.5.2 What the compiler may reason with
      3. 16.5.3 Facts: how proofs flow through code
      4. 16.5.4 The dynamic check and its panic
    6. 16.6 Behavioral Subtyping (§15.9)
    7. 16.7 Idioms & Best Practices
    8. 16.8 Foreign Contracts on extern Procedures (§23.6)
    9. 16.9 Pitfalls & Diagnostics
  17. 17. Expressions & Operators
    1. 17.1 Operator Precedence and Associativity (Overview)
    2. 17.2 Literal and Name Expressions (§16.1)
      1. 17.2.1 Syntax
      2. 17.2.2 Integer literals
      3. 17.2.3 Float, bool, char, string, unit, and null literals
      4. 17.2.4 Name expressions
    3. 17.3 Access and Place Expressions (§16.2)
      1. 17.3.1 Syntax
      2. 17.3.2 Field access
      3. 17.3.3 Tuple index
      4. 17.3.4 Indexing and slicing
    4. 17.4 Call Expressions (§16.3)
      1. 17.4.1 Syntax
      2. 17.4.2 Ordinary calls and argument passing
      3. 17.4.3 Generic calls
      4. 17.4.4 The capability / method call operator ~>
    5. 17.5 Operator Expressions (§16.4)
      1. 17.5.1 Unary operators ! and -
      2. 17.5.2 Arithmetic operators + - * / % **
      3. 17.5.3 Comparison operators == != < <= > >=
      4. 17.5.4 Logical operators && || !
      5. 17.5.5 Bitwise operators & | ^ and complement !
      6. 17.5.6 Shift operators << and >>
      7. 17.5.7 Range expressions
    6. 17.6 Cast and Transmute Expressions (§16.5)
      1. 17.6.1 Syntax
      2. 17.6.2 as casts
      3. 17.6.3 transmute
    7. 17.7 Construction Expressions (§16.6)
      1. 17.7.1 Syntax
      2. 17.7.2 Tuples
      3. 17.7.3 Arrays
      4. 17.7.4 Records
      5. 17.7.5 Enums
      6. 17.7.6 Modal state construction
    8. 17.8 Control Expressions (§16.7)
      1. 17.8.1 Syntax
      2. 17.8.2 if as an expression
      3. 17.8.3 if ... is — pattern and match expression form
      4. 17.8.4 loop as an expression
      5. 17.8.5 Block expressions
    9. 17.9 Effectful Core Expressions (§16.8)
      1. 17.9.1 Syntax
      2. 17.9.2 unsafe blocks
      3. 17.9.3 Address-of & and dereference *
      4. 17.9.4 move and copy
      5. 17.9.5 Region allocation
      6. 17.9.6 Error propagation ?
    10. 17.10 Closure and Pipeline Expressions (§16.9)
      1. 17.10.1 Syntax
      2. 17.10.2 Closures
      3. 17.10.3 Pipelines =>
    11. Idioms & Best Practices
    12. Pitfalls & Diagnostics
  18. 18. Patterns & Matching
    1. 18.1 Basic Patterns
      1. 18.1.1 Syntax
      2. 18.1.2 The four basic forms
      3. 18.1.3 Permission threading
      4. 18.1.4 Worked example
    2. 18.2 Tuple and Record Patterns
      1. 18.2.1 Syntax
      2. 18.2.2 Tuple patterns
      3. 18.2.3 Record patterns
      4. 18.2.4 Worked example
    3. 18.3 Enum and Modal Patterns
      1. 18.3.1 Syntax
      2. 18.3.2 Enum pattern semantics
      3. 18.3.3 Modal pattern semantics
      4. 18.3.4 Worked example — enums
      5. 18.3.5 Worked example — modal state
      6. 18.3.6 Worked example — Outcome
    4. 18.4 Range Patterns
      1. 18.4.1 Syntax
      2. 18.4.2 Semantics
      3. 18.4.3 Worked example
    5. 18.5 Case Clauses
      1. 18.5.1 Syntax
      2. 18.5.2 Guards via nested matching
      3. 18.5.3 Scoping and type narrowing
      4. 18.5.4 Evaluation semantics
      5. 18.5.5 Worked example — exhaustive enum dispatch with narrowing
    6. 18.6 Exhaustiveness and Reachability
      1. 18.6.1 Irrefutability and coverage
      2. 18.6.2 Enum exhaustiveness
      3. 18.6.3 Modal exhaustiveness
      4. 18.6.4 Union exhaustiveness
      5. 18.6.5 Other scrutinees
      6. 18.6.6 Reachability
      7. 18.6.7 How exhaustiveness drives safe code
      8. 18.6.8 Worked example — refactor safety
    7. 18.7 Idioms & Best Practices
    8. 18.8 Pitfalls & Diagnostics
  19. 19. Statements, Blocks, Regions, Frames & Defer
    1. 19.1 Blocks and Block Values (§18.1)
      1. 19.1.1 Grammar
      2. 19.1.2 Statement terminators
      3. 19.1.3 The block value (tail expression)
      4. 19.1.4 Scope, evaluation order, and cleanup
    2. 19.2 Binding Statements: let and var (§18.2)
      1. 19.2.1 Grammar
      2. 19.2.2 The two binding operators: = vs :=
      3. 19.2.3 Typing rules
      4. 19.2.4 Worked example
    3. 19.3 Local using Statements (§18.3)
      1. 19.3.1 Grammar
      2. 19.3.2 Semantics
      3. 19.3.3 Worked example
    4. 19.4 Assignment Statements (§18.4)
      1. 19.4.1 Grammar
      2. 19.4.2 Plain assignment
      3. 19.4.3 Compound assignment
      4. 19.4.4 Diagnostics
      5. 19.4.5 Worked example
    5. 19.5 Expression Statements (§18.5)
      1. 19.5.1 Grammar
    6. 19.6 defer (§18.6)
      1. 19.6.1 Grammar
      2. 19.6.2 Semantics
      3. 19.6.3 Ordering — LIFO
      4. 19.6.4 Worked example
    7. 19.7 region — Arena Scopes (§18.7)
      1. 19.7.1 Grammar
      2. 19.7.2 Options and alias
      3. 19.7.3 Semantics
      4. 19.7.4 Allocating into a region
      5. 19.7.5 Worked example
    8. 19.8 frame — Stack-Like Scopes (§18.8)
      1. 19.8.1 Grammar
      2. 19.8.2 Implicit vs explicit target
      3. 19.8.3 Semantics
      4. 19.8.4 Worked example
    9. 19.9 Control-Transfer Statements: return, break, continue (§18.9)
      1. 19.9.1 Grammar
      2. 19.9.2 return
      3. 19.9.3 break
      4. 19.9.4 continue
      5. 19.9.5 Interaction with cleanup
      6. 19.9.6 Worked example
    10. 19.10 unsafe Statements (§18.10)
      1. 19.10.1 Grammar
      2. 19.10.2 What unsafe enables
      3. 19.10.3 Worked example
    11. 19.11 Idioms & Best Practices
    12. 19.12 Pitfalls & Diagnostics
  20. 20. Permissions & Binding State
    1. 20.1 Permission Forms (§10.1)
      1. 20.1.1 Exact Syntax
      2. 20.1.2 Parsing
      3. 20.1.3 AST Representation
      4. 20.1.4 Static Semantics: the three regimes
      5. 20.1.5 Dynamic Semantics
      6. 20.1.6 Lowering
      7. 20.1.7 Worked example
    2. 20.2 Alias and Exclusivity Rules (§10.2)
      1. 20.2.1 Aliasing and the exclusivity invariant
      2. 20.2.2 The Coexistence Matrix
      3. 20.2.3 Dynamic semantics and lowering
      4. 20.2.4 Worked example
    3. 20.3 Binding Activity States (§10.3)
      1. 20.3.1 The two states
      2. 20.3.2 Transition rules
      3. 20.3.3 Dynamic semantics
      4. 20.3.4 Worked example
    4. 20.4 Permission Admissibility (§10.4)
      1. 20.4.1 The PermAdmits relation
      2. 20.4.2 Method receiver permissions
      3. 20.4.3 Constraints
      4. 20.4.4 Dynamic semantics and lowering
      5. 20.4.5 How permissions enable local reasoning
      6. 20.4.6 Worked example
    5. 20.5 Permissions in Parameter Signatures and move
    6. Idioms & Best Practices
    7. Pitfalls & Diagnostics
  21. 21. Authority, Capabilities, Regions & the Memory Model
    1. 21.1 The Authority Model (§6.1)
      1. 21.1.1 No Ambient Authority
      2. 21.1.2 The Four No-Ambient-Authority Requirements
      3. 21.1.3 The Idiomatic Entry Point and the Capability Call Operator ~>
      4. 21.1.4 Attenuation
      5. 21.1.5 Observable Behavior, the As-If Rule, and Sequence Points
    2. 21.2 Host Primitives (§6.2)
      1. 21.2.1 IO, File, and Directory Primitives
      2. 21.2.2 System Primitives
      3. 21.2.3 Time Primitives
      4. 21.2.4 Network Primitives
      5. 21.2.5 Heap and Reactor Primitives
    3. 21.3 Binding and Permission Runtime State (§6.3)
      1. 21.3.1 Binding State
      2. 21.3.2 Permission Activity State
      3. 21.3.3 State Transitions
      4. 21.3.4 Procedure Entry State
    4. 21.4 Regions, Frames, and Provenance (§6.4)
      1. 21.4.1 Region Options
      2. 21.4.2 The region Statement, the frame Statement, and Region Allocation
      3. 21.4.3 Provenance Tags and Lifetime Order
      4. 21.4.4 The Region Modal Type and Its Procedures
    5. 21.5 Dynamic Scope Stack, Bindings, and Region Runtime (§6.5)
      1. 21.5.1 Dynamic Scope Stack and Binding Store
      2. 21.5.2 Region Stack and Arenas
      3. 21.5.3 Address State and Pointer Expiry
    6. 21.6 Runtime State and Memory Diagnostics (§6.6)
    7. Idioms & Best Practices
    8. Pitfalls & Diagnostics
  22. 22. Attributes, Metadata & Source-Native Tests
    1. 22.1 Attribute Syntax and Placement (§9.1)
      1. 22.1.1 The attribute grammar
      2. 22.1.2 Placement
      3. 22.1.3 Well-formedness
      4. 22.1.4 Worked example
    2. 22.2 Vendor Attributes (§9.2)
    3. 22.3 Layout Attributes (§9.3)
      1. 22.3.1 Syntax
      2. 22.3.2 The layout kinds
      3. 22.3.3 Valid and invalid combinations
      4. 22.3.4 Worked example
    4. 22.4 Optimization Attributes (§9.4)
      1. 22.4.1 Syntax
      2. 22.4.2 Semantics
      3. 22.4.3 Worked example
    5. 22.5 Diagnostics and Metadata Attributes (§9.5)
      1. 22.5.1 #deprecated
      2. 22.5.2 #dynamic — runtime verification scope
      3. 22.5.3 #stale_ok
      4. 22.5.4 #static — verification mode
      5. 22.5.5 Phase-2 attributes: #reflect, #derive, #emit, #files
    6. 22.6 Source-Native Test Attributes (§9.6)
      1. 22.6.1 Syntax
      2. 22.6.2 Identity and coverage
      3. 22.6.3 Argument well-formedness
      4. 22.6.4 Required test-procedure shape
      5. 22.6.5 The TestAuthority parameter
      6. 22.6.6 Pass / fail / error semantics
      7. 22.6.7 How uv test discovers and runs tests
      8. 22.6.8 Complete #test example
    7. Idioms & Best Practices
    8. Pitfalls & Diagnostics
  23. 23. The Key System: Shared-Memory Concurrency
    1. 23.1 Why Keys Replace Runtime Mutexes
    2. 23.2 Key Paths (§19.1)
      1. 23.2.1 Key-Path Syntax
      2. 23.2.2 Path Well-Formedness
      3. 23.2.3 Path Root Extraction and Boundaries
      4. 23.2.4 Key Coarsening with #
      5. 23.2.5 shared Dynamic Class Objects
      6. 23.2.6 Worked Example — Key Paths and Coarsening
    3. 23.3 Key Acquisition Blocks (§19.2)
      1. 23.3.1 Key-Block Syntax
      2. 23.3.2 Key Triples, Modes, and Mode Ordering
      3. 23.3.3 Coverage and Implicit Acquisition
      4. 23.3.4 Explicit Block Acquisition and Canonical Order
      5. 23.3.5 Scope-Bound Release and Escape Rules
      6. 23.3.6 Closure Capture of shared Bindings
      7. 23.3.7 Worked Example — A %write Block over Two Paths
    4. 23.4 Conflict Detection (§19.3)
      1. 23.4.1 Prefix, Disjointness, and Overlap
      2. 23.4.2 Mode Compatibility and the Conflict Relation
      3. 23.4.3 Canonical Ordering
      4. 23.4.4 Dynamic-Index Conflicts and Read-Then-Write
      5. 23.4.5 The ordered Option
      6. 23.4.6 Worked Example — Disjoint Indices and a Covering Write
    5. 23.5 Nested Release (§19.4)
      1. 23.5.1 Semantics of %release
      2. 23.5.2 The Mode-Change Rule
      3. 23.5.3 Reentrancy Through shared Parameters
      4. 23.5.4 Worked Example — Downgrade to Read During a Long Scan
    6. 23.6 Speculative Execution (§19.5)
      1. 23.6.1 Speculative-Block Syntax
      2. 23.6.2 Body Restrictions
      3. 23.6.3 The Speculative State Machine
      4. 23.6.4 Worked Example — A Speculative Counter Bump
    7. 23.7 Dynamic Key Verification (§19.6)
      1. 23.7.1 Static Safety Conditions
      2. 23.7.2 Static vs. Dynamic Outcomes
      3. 23.7.3 Runtime Synchronization Guarantees
      4. 23.7.4 Worked Example — #dynamic for Data-Dependent Indices
    8. 23.8 Memory Ordering (§19.7)
      1. 23.8.1 Memory-Order Syntax
      2. 23.8.2 Ordering Levels and Effective Ordering
      3. 23.8.3 Fences
      4. 23.8.4 The Happens-Before Model and Key-Transfer Visibility
      5. 23.8.5 Worked Example — A Release Fence Around a Handoff
    9. 23.9 Key Propagation and the Static Replacement of Mutexes
    10. 23.10 Capstone Worked Example — A Guarded Shared Counter
    11. Idioms & Best Practices
    12. Pitfalls & Diagnostics
  24. 24. Structured Parallelism
    1. 24.1 Parallel Blocks (§20.1)
      1. 24.1.1 Syntax
      2. 24.1.2 Options and their static requirements (§20.1.4)
      3. 24.1.3 Static semantics (§20.1.4)
      4. 24.1.4 Dynamic semantics: fork-join (§20.1.5)
      5. 24.1.5 Worked example
      6. 24.1.6 Diagnostics (§20.1.7)
    2. 24.2 Execution Domains (§20.2)
      1. 24.2.1 Syntax and constructors
      2. 24.2.2 Domain behaviors
      3. 24.2.3 GPU intrinsics, memory, and safety
      4. 24.2.4 Domain example
      5. 24.2.5 Diagnostics (§20.2.7)
    3. 24.3 Capture Semantics (§20.3)
      1. 24.3.1 CPU capture rules (§20.3.4)
      2. 24.3.2 GPU capture rules (§20.3.4)
      3. 24.3.3 Capture example
      4. 24.3.4 Diagnostics (§20.3.7)
    4. 24.4 Spawn, Spawned<T>, and Wait (§20.4, §21.2)
      1. 24.4.1 Spawn syntax (§20.4.1)
      2. 24.4.2 Spawn options and typing (§20.4.4)
      3. 24.4.3 The Spawned<T> modal (§13.1.4)
      4. 24.4.4 Spawn dynamic semantics (§20.4.5)
      5. 24.4.5 Wait (§21.2)
      6. 24.4.6 Spawn/wait example
      7. 24.4.7 Diagnostics (§20.4.7, §21.2.7, §21.5.7)
    5. 24.5 Dispatch — Parallel Loops (§20.5)
      1. 24.5.1 Syntax (§20.5.1)
      2. 24.5.2 Typing (§20.5.4)
      3. 24.5.3 Dependency safety and key inference (§20.5.4)
      4. 24.5.4 Reduction, ordering, and chunking (§20.5.4)
      5. 24.5.5 Dispatch dynamic semantics (§20.5.5)
      6. 24.5.6 Dispatch examples
      7. 24.5.7 Diagnostics (§20.5.7, §20.9)
    6. 24.6 Cancellation (§20.6)
      1. 24.6.1 The CancelToken modal (§20.6.3, §20.6.4)
      2. 24.6.2 Attaching and propagating (§20.6.5)
      3. 24.6.3 Cancellation example
      4. 24.6.4 Diagnostics (§20.6.7)
    7. 24.7 Panic Handling Across Tasks (§20.7)
      1. 24.7.1 Semantics (§20.7.5)
      2. 24.7.2 Panic-handling example
      3. 24.7.3 Diagnostics (§20.7.7)
    8. 24.8 Determinism and Nesting (§20.8)
      1. 24.8.1 Determinism (§20.8.4, §20.8.5)
      2. 24.8.2 Nesting (§20.8.4, §20.8.5)
      3. 24.8.3 Nesting example
      4. 24.8.4 Diagnostics (§20.8.7)
    9. 24.9 Worked Structured-Concurrency Example
    10. Idioms & Best Practices
    11. Pitfalls & Diagnostics
  25. 25. Asynchronous Operations
    1. 25.1 The Async Type
      1. 25.1.1 The four type parameters
      2. 25.1.2 The three states
      3. 25.1.3 Syntax and parsing
      4. 25.1.4 Built-in aliases
      5. 25.1.5 AsyncSig — the normalization that drives every async rule
      6. 25.1.6 Subtyping and variance
      7. 25.1.7 Well-formedness and diagnostics
      8. 25.1.8 Worked example — declaring async procedures
    2. 25.2 Suspension Forms
      1. 25.2.1 wait — awaiting a handle
      2. 25.2.2 yield — suspending the current async computation
      3. 25.2.3 yield from — delegating to another async value
      4. 25.2.4 Key restrictions
    3. 25.3 Composition Forms
      1. 25.3.1 Async iteration — loop pat in async
      2. 25.3.2 Manual stepping
      3. 25.3.3 sync — driving an async to completion synchronously
      4. 25.3.4 race — first-to-settle wins
      5. 25.3.5 all — join all results
      6. 25.3.6 The async combinators
      7. 25.3.7 until — a source-specified surface on shared values
      8. 25.3.8 Composition diagnostics
    4. 25.4 The Async State Machine Model
      1. 25.4.1 What "async procedure" means structurally
      2. 25.4.2 The async frame
      3. 25.4.3 Settlement — how the three states are produced
      4. 25.4.4 Error propagation inside async procedures
      5. 25.4.5 Capture and escape provenance
      6. 25.4.6 Lowering (informative)
      7. 25.4.7 State-machine diagnostics
    5. 25.5 Async–Key Integration
      1. 25.5.1 The three key restrictions
      2. 25.5.2 yield release — suspend while holding keys
      3. 25.5.3 Shared-capturing closures with yield
      4. 25.5.4 Staleness across yield release
      5. 25.5.5 Async capability requirements
      6. 25.5.6 Async–key diagnostics
    6. Idioms & Best Practices
    7. Pitfalls & Diagnostics
  26. 26. Compile-Time Execution & Metaprogramming
    1. 26.1 Compile-Time Forms (§22.1)
      1. 26.1.1 Exact Syntax
      2. 26.1.2 What May Run at Compile Time
      3. 26.1.3 comptime Statement and comptime Expression
      4. 26.1.4 comptime if
      5. 26.1.5 comptime loop
      6. 26.1.6 Compile-Time Procedures
      7. 26.1.7 Phase 2 Execution Order and Emission Visibility
    2. 26.2 Compile-Time Capabilities (§22.2)
      1. 26.2.1 Availability
      2. 26.2.2 TypeEmitter
      3. 26.2.3 Introspect
      4. 26.2.4 ProjectFiles
      5. 26.2.5 ComptimeDiagnostics
    3. 26.3 Reflection (§22.3)
      1. 26.3.1 The Type::<T> Literal
      2. 26.3.2 Categories
      3. 26.3.3 Reflectability
      4. 26.3.4 Member Queries
      5. 26.3.5 Type Predicates and Names
      6. 26.3.6 Worked Example
    4. 26.4 Quote, Splice, and Emission (§22.4)
      1. 26.4.1 Exact Syntax
      2. 26.4.2 Quote Kind Resolution
      3. 26.4.3 Splicing Rules
      4. 26.4.4 Hygiene
      5. 26.4.5 Emission
      6. 26.4.6 Worked Example
    5. 26.5 Derive Targets and Contracts (§22.5)
      1. 26.5.1 Exact Syntax
      2. 26.5.2 Validity and Bindings
      3. 26.5.3 Derive Contracts and Ordering
      4. 26.5.4 Execution Semantics
      5. 26.5.5 Worked Example
    6. 26.6 Idioms & Best Practices
    7. 26.7 Pitfalls & Diagnostics
  27. 27. Foreign Function Interface (FFI)
    1. 27.1 FfiSafe — Which Types May Cross the Boundary
      1. 27.1.1 The FFI-safe primitive set
      2. 27.1.2 Compound FFI-safe types
      3. 27.1.3 Prohibited type categories
      4. 27.1.4 Generic bounds and the by-value RAII rule
      5. 27.1.5 Worked example — an FFI-safe record and a generic FFI-safe record
      6. 27.1.6 Diagnostics (§23.1.7)
    2. 27.2 Extern Procedures — Calling Foreign Code
      1. 27.2.1 Syntax
      2. 27.2.2 ABI strings
      3. 27.2.3 Signature requirements
      4. 27.2.4 Call safety
      5. 27.2.5 Dynamic semantics
      6. 27.2.6 Worked example — declaring and calling a C function
      7. 27.2.7 Diagnostics (§23.2.7)
    3. 27.3 Foreign-Callable Procedure Exports — Exposing Ultraviolet to Foreign Callers
      1. 27.3.1 Raw exported procedures
        1. Worked example — a raw export
      2. 27.3.2 Hosted exports
        1. Worked example — a hosted export
      3. 27.3.3 Diagnostics (§23.3.1.7, §23.3.2.7)
    4. 27.4 FFI Attributes
      1. 27.4.1 Syntax (§23.4.1)
      2. 27.4.2 #mangle
      3. 27.4.3 #library
      4. 27.4.4 #unwind
      5. 27.4.5 #export and #host_export
      6. 27.4.6 #ffi_pass_by_value
      7. 27.4.7 Diagnostics (§23.4.7)
    5. 27.5 Capability Isolation Across the FFI Boundary
    6. 27.6 Foreign Contracts
      1. 27.6.1 Syntax (§23.6.1)
      2. 27.6.2 Foreign preconditions — @foreign_assumes
      3. 27.6.3 Foreign postconditions — @foreign_ensures
      4. 27.6.4 Worked example — a contract-bearing extern
      5. 27.6.5 Diagnostics (§23.6.7)
    7. 27.7 The extern Block Shell (§11.4)
      1. 27.7.1 Syntax (§11.4.1)
      2. 27.7.2 Semantics
      3. 27.7.3 Worked example — a complete extern block
    8. 27.8 Boundary Unwinding and Panic Safety
      1. 27.8.1 Boundary effects (§23.7.5)
      2. 27.8.2 Code generation (§23.7.6)
      3. 27.8.3 Worked example — a panic-safe export
    9. Idioms & Best Practices
    10. Pitfalls & Diagnostics
  28. 28. Program Lifecycle, Drop, ABI & Runtime
    1. 28.1 The Target Profile
    2. 28.2 Layout & ABI Essentials
      1. 28.2.1 Primitive Sizes and Alignments
      2. 28.2.2 Default Calling Convention
      3. 28.2.3 Parameter and Return Passing
    3. 28.3 Symbols, Mangling & Linkage
      1. 28.3.1 How names are produced
      2. 28.3.2 Linkage
    4. 28.4 Initialization & Program Lifecycle
      1. 28.4.1 The main entry contract
      2. 28.4.2 The entry stub and startup sequence
      3. 28.4.3 Static globals and initialization order
      4. 28.4.4 Initialization panics and poisoning
      5. 28.4.5 The panic-out parameter
      6. 28.4.6 Interpreter and library lifecycles
    5. 28.5 Cleanup, Drop & Unwinding
      1. 28.5.1 What "drop" means
      2. 28.5.2 Drop order
      3. 28.5.3 defer
      4. 28.5.4 The cleanup driver, panics during cleanup, and abort
      5. 28.5.5 Static teardown
    6. 28.6 Temporary Cleanup
    7. 28.7 The Runtime Interface
    8. 28.8 Backend Requirements (Reference Level)
    9. Idioms & Best Practices
    10. Pitfalls & Diagnostics
  29. 29. Complete Grammar Reference
    1. 29.1 B.1 — Lexical Grammar
    2. 29.2 B.2 — Type Grammar
    3. 29.3 B.3 — Expression Grammar
    4. 29.4 B.4 — Pattern Grammar
    5. 29.5 B.5 — Statement Grammar
    6. 29.6 B.6 — Declaration Grammar
    7. 29.7 B.7 — Contract Grammar
    8. 29.8 B.8 — Attribute Grammar
    9. 29.9 B.9 — Key System Grammar
    10. 29.10 B.10 — Concurrency Grammar
    11. 29.11 B.11 — Async Grammar
    12. 29.12 B.12 — Metaprogramming Grammar
    13. 29.13 B.13 — FFI Grammar
    14. 29.14 B.14 — Region Grammar
    15. 29.15 Appendix C — AST Form Index (Quick Map)
      1. 29.15.1 C.1 Item Forms
      2. 29.15.2 C.2 Type Forms
      3. 29.15.3 C.3 Expression, Pattern, and Statement Families
    16. 29.16 Cross-Section Token Cautions
    17. 29.17 Idioms & Best Practices
    18. 29.18 Pitfalls & Diagnostics
  30. 30. Style, Naming & Engineering Best Practices
    1. 30.1 Naming
      1. 30.1.1 General Rules
      2. 30.1.2 The Naming Matrix
      3. 30.1.3 Acronyms and Initialisms
      4. 30.1.4 Naming Exceptions
    2. 30.2 Formatting
      1. 30.2.1 Layout
      2. 30.2.2 Line Breaking
      3. 30.2.3 Spacing and Blank Lines
    3. 30.3 Module, Directory, and File Organization
      1. 30.3.1 Module Structure
      2. 30.3.2 File and Module Size
      3. 30.3.3 Special Files
    4. 30.4 Imports and Visibility
      1. 30.4.1 Import Ordering
      2. 30.4.2 using Rules
      3. 30.4.3 Visibility
    5. 30.5 Type Design
      1. 30.5.1 record, class, and modal
      2. 30.5.2 Member Ordering
    6. 30.6 Contracts, Invariants, and Safety Semantics
      1. 30.6.1 Contracts Are Mandatory Where Expressible
      2. 30.6.2 Capability Passing
      3. 30.6.3 State and Validation
    7. 30.7 unsafe, #dynamic, and FFI
      1. 30.7.1 unsafe
      2. 30.7.2 #dynamic
      3. 30.7.3 FFI Boundaries
    8. 30.8 Procedures and API Design
      1. 30.8.1 Procedure Style
      2. 30.8.2 API Surface
    9. 30.9 Module-Scope State
    10. 30.10 Comments and Documentation
      1. 30.10.1 Comments
      2. 30.10.2 Documentation Comments
    11. 30.11 Review Expectations
    12. Idioms & Best Practices
    13. Pitfalls & Diagnostics