Every host compilation must see the standard library graph.
FAQ and troubleshooting
Platform spec article
FAQ and troubleshooting
Spec standingStandard
-
Parser rejects noCorelib and useCorelib false.
Context
Decision
Rule Detail Forbidden keys noCorelib,useCorelib: falserejected at parseTemplates Scaffolds must not emit opt-out keys Consequences
Implicit injection in
resolve_dependenciesalways attaches corelib.Verification anchors
projects/parser.rs; template manifest tests. -
Corelib member packages must not implicit-back-link to aggregate.
Context
Shards under
packages/*would create cycles if they gained implicit host edges.Decision
Rule Detail Guard is_corelib_workspace_shard_manifestskips implicit back-edgeHost Only application hosts receive implicit corelib Consequences
Building
packages/runtimealone does not pull beskid_corelib as a hidden parent.Verification anchors
resolver.rs; corelib workspace compile tests. -
Compiler mods compile as carriers without host corelib rules.
Context
Mods are not end-user hosts; injecting corelib would distort mod graphs.
Decision
Rule Detail ModDoes not receive implicit host injection HostReceives implicit corelib per D-CORE-COMP-0005 Consequences
Mod SDK projects declare their own dependency closure.
Verification anchors
Mod project tests in
beskid_tests. -
CLI and LSP share corelib discovery and graph options.
Context
IDE analysis must match CLI compilation attachment.
Decision
Rule Detail CLI ensure_corelib_readybefore commandsLSP CompilationContext::try_for_analysis_path_with_graph_optionsConsequences
Diagnostic drift between CLI and LSP indicates a resolver bug.
Verification anchors
LSP workspace tests;
corelib/compile.rs.
- Contracts and edge cases Corelib injection guarantees and edge cases.
- Design model How the compiler injects and resolves the corelib package into host compilations.
- Examples Observable corelib injection scenarios.
- FAQ and troubleshooting Corelib injection and resolution FAQ.
- Flow and algorithm End-to-end flow for corelib injection during project graph resolution.
- Verification and traceability Tests and traceability for corelib injection and resolution.
0 revisions (git unavailable at build; counts may be empty)
No commits recorded for this path.
| Section id | Required | Found |
|---|---|---|
what-this-feature-specifies | yes | yes |
implementation-anchors | yes | yes |
Full tree: run pnpm verify:platform-spec-layout (writes src/generated/platform-spec-layout-report.json).
Can I disable corelib for a micro-benchmark?
Section titled “Can I disable corelib for a micro-benchmark?”No. Host projects always load corelib. Isolate benchmarks in Mod or non-host tooling paths that do not claim to be full language hosts.
Std not found despite submodule checkout
Section titled “Std not found despite submodule checkout”Initialize compiler/corelib submodule and set BESKID_CORELIB_ROOT to the directory containing beskid_corelib/Project.proj.
Duplicate corelib in graph
Section titled “Duplicate corelib in graph”Usually caused by both implicit injection and an explicit Std path to a different tree. Align paths to one aggregate root.
LSP missing prelude types
Section titled “LSP missing prelude types”Focused project must be a host under the same corelib root the CLI uses. Rescan workspace after changing BESKID_CORELIB_ROOT.
Mod project pulls corelib twice
Section titled “Mod project pulls corelib twice”Mods depend on host graphs; they should not redeclare aggregate corelib unless packaging tests require it—follow Project manifest contract Mod rules.