pr 03.03
This commit is contained in:
@@ -6,52 +6,6 @@
|
||||
|
||||
---
|
||||
|
||||
## PR-03.02 — Ban PBS leakage at the BE boundary (dependency & import hygiene)
|
||||
|
||||
### Title
|
||||
|
||||
Remove PBS imports from BE layers and enforce `frontend-api` boundary
|
||||
|
||||
### Briefing / Context
|
||||
|
||||
BE code currently imports PBS modules (symbols, typed builder, etc.) from `prometeu-compiler`. This is the leak that makes the system unmaintainable and creates accidental coupling. We must ensure BE only depends on `frontend-api` outputs.
|
||||
|
||||
### Target
|
||||
|
||||
* BE layers (`building/*`, `sources.rs`, orchestrator/linker paths) **must not import PBS modules**.
|
||||
* Any FE-specific logic is moved behind the `Frontend` implementation.
|
||||
|
||||
### Scope
|
||||
|
||||
* Replace `use crate::frontends::pbs::*` imports in BE files with `frontend-api` types.
|
||||
* Add a simple compile-time guard:
|
||||
|
||||
* Option A: a `deny`/lint via `mod` separation + no re-exports.
|
||||
* Option B: create `crates/prometeu-compiler-backend` module that does not depend on `pbs` module.
|
||||
* Identify and remove PBS-specific helper calls inside BE (e.g., `build_typed_module_symbols` from BE).
|
||||
|
||||
### Out of scope
|
||||
|
||||
* Fixing overload resolution itself (handled in later PRs).
|
||||
|
||||
### Checklist
|
||||
|
||||
* [ ] Update imports in BE files.
|
||||
* [ ] Remove PBS type references from BE data structures.
|
||||
* [ ] Ensure build compiles without BE → PBS direct dependency.
|
||||
* [ ] Add a “boundary test”: a module that `use`s backend and fails to compile if PBS is required (or a CI check script).
|
||||
|
||||
### Tests
|
||||
|
||||
* `cargo test -p prometeu-compiler`
|
||||
* `cargo test --workspace`
|
||||
|
||||
### Risk
|
||||
|
||||
Medium. Refactor touches build/orchestrator wiring.
|
||||
|
||||
---
|
||||
|
||||
## PR-03.03 — Canonical import syntax → `ImportRef` (no dual styles)
|
||||
|
||||
### Title
|
||||
|
||||
Reference in New Issue
Block a user