Skip to content

Normalize .codc artifact paths for dotted units and reset PTAC register sequencing per artifact#94

Merged
DanexCodr merged 5 commits into
mainfrom
copilot/fix-codb-file-structure
Apr 13, 2026
Merged

Normalize .codc artifact paths for dotted units and reset PTAC register sequencing per artifact#94
DanexCodr merged 5 commits into
mainfrom
copilot/fix-codb-file-structure

Conversation

Copilot AI commented Apr 13, 2026

Copy link
Copy Markdown
Contributor

.codb entries inside project.codc were being keyed by raw unit name (e.g., test.lazyloop/...) instead of nested unit paths (test/lazyloop/...). This caused incorrect container layout for any dotted unit and inconsistent artifact path handling.

  • Container + fallback path normalization

    • IRManager now normalizes unit names via a shared toUnitPath(...) (./) for:
      • .codc entry names
      • standalone .codb fallback file paths
    • This makes storage/loading consistent across all dotted units, not just lazyloop.
  • Runner path output consistency

    • CommandRunner and TestRunner now use the same shared unit-path normalization for compile/debug artifact paths, so logs reflect actual container layout.
  • Bytecode “register next” stability

    • Lowerer now resets internal temp/pattern/lambda counters at the start of each lower(...) call.
    • This ensures deterministic per-artifact register/symbol allocation instead of carrying counter state across compiles.
// Before: entry path built from raw unit name
return unit + "/" + className + ".codb";

// After: dotted units are normalized once and reused everywhere
return toUnitPath(unit) + "/" + className + ".codb";
// e.g. "test.lazyloop" -> "test/lazyloop"

@DanexCodr DanexCodr marked this pull request as ready for review April 13, 2026 03:44
@DanexCodr DanexCodr merged commit d2f9a44 into main Apr 13, 2026
@DanexCodr DanexCodr deleted the copilot/fix-codb-file-structure branch April 13, 2026 03:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants