Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
symbolique
Generic symbol table pipeline for compilers and language servers, built on laburnum's partition system.
Pipeline
Symbols flow through 4 stages, each backed by a laburnum partition:
Symbols (CAS) ← Content-addressed symbol storage (shared across all stages)
│
FileSymbols ← Stage 1: Parse - per-file symbol index
│
LinkedSymbols ← Stage 2: Link - cross-file import resolution
│
MergedSymbols ← Stage 3: Merge - combined namespace
│
SymbolResolution ← Stage 4: Resolve - reference → definition mapping
Each stage writes index entries pointing to shared Symbol records in the CAS partition.
Integration with Laburnum
The pipeline stages map to laburnum's task-based incremental computation model:
| Stage | Partition | Writer Trait | Invalidation |
|---|---|---|---|
| Parse | FileSymbols |
SymboliqueWriteExt |
When file content changes |
| Link | LinkedSymbols |
LinkedSymboliqueWriteExt |
When imported file changes |
| Merge | MergedSymbols |
MergedSymboliqueWriteExt |
When any file in package changes |
| Resolve | SymbolResolution |
ResolutionWriteExt |
When any linked table changes |
All writes go through PartitionWriteContextRef using the writer extension traits.
Type Parameters
All partition types are generic over three parameters:
| Parameter | Trait | Purpose |
|---|---|---|
V |
Value<I> |
Literal values in your language |
I |
Ident |
Identifier representation |
P |
SymbolPath |
Path representation (default: String) |
Default implementations are provided:
StringIdent- String-based identifiersDefaultValue- Common literal types (String, Integer, Float, Boolean)
Symbol Types
The Symbol enum represents 6 patterns:
| Variant | Purpose | Example |
|---|---|---|
Definition |
Named entities | Functions, variables, types |
Reference |
Names referring to other symbols | Variable usage, path access |
Scope |
Anonymous containers | Blocks, namespaces |
Keyword |
Reserved words | if, let, fn |
Value |
Literal values | 42, "hello" |
Import |
Imported symbols | use math::add |
Writing Symbols
Each stage has a writer extension trait on PartitionWriteContextRef. Writers store the Symbol record in the CAS partition and create a SymbolEntry index entry in the stage's partition.
use ;
// In an on_file_version hook or similar task:
writer.write_symbol_definition;
writer.write_symbol_reference;
The linked and merged stages follow the same pattern with LinkedSymboliqueWriteExt and MergedSymboliqueWriteExt.
Resolution
The resolution stage maps references to their targets using ResolutionWriteExt:
use ResolutionWriteExt;
writer.write_resolution;
Custom Resolution
Implement SymboliqueResolver for your language's resolution behavior:
use ;
;
The Resolution enum has these variants:
Resolved(SymbolEntry)- Successfully resolvedDeferred- Process in next pass (for multi-pass resolution)Phantom(PhantomSymbol)- Resolved to external/synthetic symbolWrongKind { found, expected_kinds }- Found but wrong typeFailed(String)- Resolution failed with error message
Key Types
SymbolEntry
The index entry type used across all stages. Pairs a span with a content-addressed handle to the symbol record:
ResolutionEntry
The index entry for the resolution stage. Maps a reference to its resolved target: