Programming Language

Nocter

A self-contained systems language built around simplicity, encapsulation, and foolproof design.

/development/compiler/crates/nocter-declarations/README.md

nocter-declarations

Responsibility

Own the immutable, syntax-independent declaration graph and its namespaces, visibility, callable, requirement, standard-role, and target metadata.

Contract

The crate supplies domain types, builders, and validated immutable products. It knows semantic identities and normalized declaration relationships but not source text, syntax trees, editor coordinates, or checking internals.

Internal Responsibilities

  • declaration and member arenas
  • module, import, and prelude namespaces
  • callable, constant, and requirement contracts
  • visibility and path contracts
  • accepted/recovery admission shapes

Invariants

  • Builders reserve and define every identity exactly once before freeze.
  • Namespace lookup consumes frozen tables rather than iterating declarations.
  • A declaration identity never contains a source range or rendered name.
  • Invalid or incomplete graphs cannot be constructed as accepted programs.