Skip to main content

Module loader

Module loader 

Source
Expand description

Multi-file schema loader.

Structs§

Discovered
A discovered *.prax file with its absolute and relative paths.
LoadError
Error returned by load, carrying the partial source map built up to the point of failure so the renderer can resolve SourceIds back to file content.
LoadedSchema
A successfully loaded multi-file (or single-file) schema, paired with the source map needed for downstream diagnostics rendering.
SourceFile
A single source file (path + content) loaded into the schema.
SourceId
Opaque, dense identifier for a source file in a SourceMap.
SourceLoc
A (source file id, span) pair used in cross-file diagnostics.
SourceMap
Map of SourceId -> SourceFile.

Enums§

MergeConflict
A single conflict found while merging two Schemas.

Functions§

discover
Recursively find all *.prax files under root, sorted lexicographically by the relative path.
load
Load a schema from a file or directory.